The three virtues of a programmer: Laziness, Impatience, and Hubris. – Larry Wall
A revert is to undo all changes made to an article page after a specific time in the past. The result will be that the page becomes identical in content to the page saved at that time.
A partial revert is accomplished either by an ordinary edit of the current version, or by editing an old version. The former is convenient, for example, for a partial reversion of a recent addition, while the latter is convenient for a partial reversion of a deletion.
When to revert
Reverting should be taken very seriously and is often used to fight vandalism and similar abuse. If you are not sure whether a revert is appropriate, discuss it first. You can revert your own edit if you realize you were wrong, but watch out for other users editing the page in the meantime! If only part of an edit is problematic, consider modifying only that part instead of reverting the whole edit.
If your edit gets reverted, don't take it personally and by all means don't do anything silly like starting an edit war. Instead, go to the relevant discussion page and see if the user who reverted your edit explained why he did it. You can explain why you made the edit that was subsequently reverted and together you and other users will eventually decide whether to add it back or not.
How to revert
- Go to the page's history and click on the time and date of the earlier version you wish to revert to.
- When that page comes up, you'll see the revision number and date below the title, along with the username of the editor who saved that version.
- Verify that you have selected the correct version, and click to edit the page, as you would normally. Important: In the case of vandalism, take the time to ensure you are actually reverting to the last version without the vandalism; there may be multiple consecutive vandal edits, sometimes interspersed with constructive edits.
- You will get a warning, above the edit box, about editing an out-of-date revision. Since this exactly what you want to do, you can ignore it.
- Add an edit summary, then save the page. Be sure to include the word "revert" or "rv" in the summary. The summary should preferably also contain the name of the user whose edit was reverted and that of the user whose version was reverted to. A good example would be:
revert edits of [[User:BadGuy]] to last version of [[User:GoodGuy]]where BadGuy is replaced with the IP address or username of the user whose edit is being reverted and GoodGuy is the name or IP address of the user who saved the version you are reverting to.
- When reverting blatant vandalism, you can simply write "rvv" (short for "revert vandalism") in the edit summary, because in those cases speed is usually more important that a precise edit summary.
- Click on "history" again to verify that your revert was successful. If your revert also affected legit edits, please edit those changes again.
- In a vandalism case where sections of text were simply deleted and then subsequent edits were made by others, it may be easier for you to cut and paste those missing sections of text back in than to revert and then re-do the edits.
- Check the contribution history of the user who vandalized the article by clicking on the IP address for unregistered users or on "contribs" on the history page. If the user is vandalizing many pages, please report him or her on the vandalism discussion page.
Latest versions of MediaWiki allow editors to revert a single edit from the history of a page without simultaneously undoing all constructive changes that have been made since. To do this, view the diff for the edit, and click on 'undo' above the newer version. The software will attempt to create an edit page with a version of the article in which the undesirable edit has been removed but all later edits are retained. There is a default edit summary, but it can be changed. It is also possible to make further modifications before saving.
This feature removes the need to manually redo useful changes that were made after the edit which is being reverted. However, it will fail if undoing the edit would conflict with later edits. For example, if edit 1000 adds a paragraph and edit 1005 modifies that paragraph, it will be impossible to automatically undo edit 1000. In this case, you must determine how to resolve the problem manually.
Administrators and users who have been granted access to the tool have additional "rollback" links, which:
- appear only next to the top edit
- revert all top consequent edits made by last editor
- work immediately, without intermediate confirmation diff page
- add automatic edit summary "Reverted edits by Example (talk) to last version by Example2", marking edit as minor
Rollback links appear on the User contributions pages, History pages and Diff pages. Note that in the last case rollback link can be misleading, since reversion is not necessarily to the old version shown (the diff page may show the combined result of edits including some by other editors, or only part of the edits the rollback button would revert). To see the changes the rollback button will revert, view the specific diff which compares the last version from the last editor with the last version from the previous editor.
Rollback works much quicker than undo, since it
- allows reverting without even looking at the list of revisions or a diff
- does not require loading an edit page and sending the wikitext back to the server.
- does not require a click of the save button.
On the other hand, it is not as versatile as undo, since it does not allow to specify which edits have to be undone (one may want to revert more or fewer edits than rollback does, or edits which do not include the last edit) and does not allow adding an explanation to the automatic edit summary.
Rollback is supposed to be used to revert obvious vandalism.
Rolling back a good-faith edit without explanation may be misinterpreted as "I think your edit was no better than vandalism and reverting it doesn't need an explanation." Some editors are sensitive to such perceived slights; if you use the rollback feature other than for vandalism (for example because undo is impractical due to the large page size), it's polite to leave an explanation on the article talk page or on the talk page of the user whose edit(s) you reverted.
If someone else edited or rolled back the page before you clicked "rollback" link, or if there was no previous editor, you will get an error message.