User scripts are programs written in JavaScript, for use on Wikipedia by users. User scripts enable your user account to do many things that they otherwise couldn't. Many user scripts are available ready for you to install. Users may also write new user scripts, starting with an existing user script and modifying it, or starting from scratch.
JavaScript is the programming language used to write user scripts. For an overview of Wikipedia's coverage about JavaScript in the form of a structured topic list, see Outline of JavaScript.
The JavaScript WikiProject is the collaboration of editors to improve WP's JavaScript coverage, write user scripts, and maintain user script-related pages (like the one you are reading right now). If you would like to join, sign up here.
Where can I find user scripts?
Try these pages:
Wikipedia:User scripts/List – main script list
Category:Wikipedia scripts – the category page
User:Writ Keeper/Scripts – 27 scripts!
How do you install user scripts?
Select one that you want from Wikipedia:User scripts/List. Either click on the superscript link (if there is one) and follow the instructions in the footnote, or follow the link with the script's name to read the documentation and find out how to install it. Normally you need to paste some code into your common.js page. After you do that, publish your common.js and follow the instructions at the top of your new common.js (the part about bypassing your browser's cache). You should now be able to use the script.
Step-by-step instructions
Simple method for scripts which are located on English Wikipedia.
First, make sure you are registered and logged in. Only logged-in users can install scripts.
Click here to edit your common.js file.
Add the following line: {{subst:iusc|script_path}} -- replace "script_path" with the full name of the .js page that opens when a script's "(source)" link is clicked.
For example, to install the Sharebox script, add the following line: {{subst:iusc|User:TheDJ/sharebox.js}}
Save the page and bypass your cache to make sure the changes take effect.
Automatic installer
Script Installer makes script installations fully automatic. The installer itself must first be installed manually. Afterwards, most scripts can be installed with a single click.
Full manual instructions
First, make sure you are registered and logged in. Only logged-in users can install scripts.
Edit your common.js file. Alternatively, you may use your skin.js to work only your current skin.
Add the following line: importScript('script_path'); -- where "script_path" is the full name of the .js page that opens when a script's "(source)" link is clicked.
For example, to install the Sharebox script, add the following line: importScript('User:TheDJ/sharebox.js');
For scripts not located on this wiki, use:
mw.loader.load('//en.wikipedia.org/w/index.php?title=script.js&action=raw&ctype=text/javascript');
Consider adding a backlink by adding //[[script_path]] to the end of the line, which aids script usage statistics.
Save the page and bypass your cache to make sure the changes take effect.
How do you add new scripts to the scripts list?
Main page: Wikipedia:User scripts/List
Use {{userscript}}. Include at least a code page address. Add a short description after the userscript template. For example:
*{{userscript | name= My script | code= User:Me/MyJSpage.js | doc= User:Me/MyJSdocumentationPage }} - This script does something useful.
Name defaults to the code page's name, without its path or ".js".
If a documentation page exists matching your .js page name, it will be linked automatically, without the need for a doc parameter.