Help:Wikipedia: The Missing Manual/Editing, creating, and maintaining articles/Who did what: Page histories and reverting
![]() | This help page needs to be updated. The reason given is: this manual may contain out of date images. Please help update this help page to reflect recent events or newly available information. Relevant discussion may be found on the talk page. (February 2020) |
Anyone can edit Wikipedia. Most of the time that's a good thing—millions of people have made positive contributions to the largest group-writing effort in human history. Then there are the problem children: those who can't resist the urge to deface an article, or delete all its content (a practice known as blanking a page), and those who add incorrect information, deliberately or by mistake. Fortunately, Wikipedia has robust change-tracking built into it: Whatever one editor does, another can reverse, returning an article to precisely what it was before.
Apart from vandalism, as an editor you're likely to want to see what other editors do to articles you've edited, whether they're on your watchlist (see the section about your watchlist) or not. While Wikipedia's change-tracking system isn't hard to understand, you'll probably find it isn't totally intuitive. In this chapter you'll learn how to quickly read through even a convoluted page history, how to see what's happened since you last edited an article, how to restore an earlier version of an article with just a few clicks, and how to deal with a problem edit followed by other edits you don't want to delete.
Understanding page histories
[edit]When you're working on, say, an Excel spreadsheet, you can't turn back time and look at what the document was like last Tuesday at 10:05 a.m. Wikipedia is different—its database has a copy of every version of every page ever created or edited. If you click on a page history tab, you can see the text on that page at whatever date and time you pick. The page history also shows you every single edit since then (or before then, for that matter).
Why Wikipedia keeps a record of everything
[edit]Keeping a copy of every revision of every page means storing a lot of data. But it's integral to Wikipedia's success. Here are the main benefits to having a record of everything:
- Responsibility. Page histories show who did what to a page, when, and often even why. Thousands of Wikipedia editors are warned, every day, for inappropriate editing. Hundreds of user accounts are blocked every day for vandalism, disruptive editing, spamming, and so on. Page histories help identify problematic edits and problem editors.
- Reverting. You can use page histories to easily revert (that is, reverse) another editor's inappropriate edit—or even your own edit, if you've made a mistake. (More on reverting in the section about reverting.)
- Reputation. Because your edits will be visible to everyone, forever, you own them forever. Hopefully, you'll think twice before damaging the good work of others. That's how most editors behave, at least.
- Liability. The Wikimedia Foundation claims it isn't legally liable for any deliberately false information that an editor adds to an article, and legal cases to date have supported that position. Instead, it's the editor who's liable. A page history, by establishing exactly who changed the article, what they changed, and when, makes it clear that the Foundation didn't create or edit a page—individual editors did.
Reviewing a page's prior versions and edits
[edit]If you want to look at individual edits to and prior versions of a page, near the top of the window, just click the "history" tab. The list that appears shows the most recent edits/versions—up to 50, if the page has been edited that many times. The list's top row is the most recent version of the article; the bottom row is the oldest, as you see if you look at the dates and times.
You can use a page history in one of three ways:
- You can simply read it to get a general sense of who did what and when.
- You can get a sense of how the text has changed by looking at individual edits, or a group of consecutive edits.
- You can click the date and time listed for a prior version of the page to read that particular version.
This section shows you how to read and interpret a page history in detail.
Reading a page history—The basics
[edit]You can learn a lot by simply reading a page history. Figure 5-1 is a snapshot of the history page for the Wikipedia article on Thomas Kean. If you've never seen a history page before, it probably looks confusing. But each of its many elements has a simple purpose.
![](http://upload.wikimedia.org/wikipedia/commons/thumb/a/a0/Wikipedia-The_Missing_Manual_0501.png/640px-Wikipedia-The_Missing_Manual_0501.png)
Here's a grand tour of the page history for the Thomas Kean article in Figure 5-1:
- On the left, the first few columns—(cur), (last), and the radio button—let you tell Wikipedia which versions of the article you want to compare, which you'll learn exactly how to do in the section about seeing what changed. If you're not comparing versions, you can ignore these columns—they're always the same.
- Next comes the time and date a version was created (or, in other words, the time and date an edit was published). The time shown is Coordinated Universal Time (UTC), which is for most practical purposes the same as Greenwich Mean Time (GMT). UTC is 5 hours ahead of Eastern Standard Time in the U.S., and uses a 24-hour system of notation rather than a.m. and p.m. So, for example, 19:05 UTC is 14:05 EST, which is 2:05 p.m. EST.
- Notice that the six versions span almost 2 months. From that you can infer that the article's subject isn't very controversial; the article doesn't get a lot of readers (because if it did, a few of them would probably edit it a bit); and there hasn't been much in the news about this person during the 2-month period of these six edits.
- To the right of the date is the name of the editor, with links to the editor's user page (click the name), the editor's user talk page, and to the "contribs" page that lists that editor's edits (called contributions). Sometimes when evaluating an edit, you want to see what else the editor has done. If so, you can follow the link to the user talk page (to look for warnings posted by other editors) or the link to the user contributions page (to look at the number of edits, what articles were edited, and even—via a link on that page—whether the editor has been blocked by an administrator to prevent further problems).
- The upper three rows (versions) in Figure 5-1 list the count of bytes (a byte is roughly one character) in those versions. Byte counts can tell you if much has changed. In this case, not much—the most recent and second-most-recent edits removed a net 17 and 9 bytes of information, respectively.
- The lower (older) three listed versions have a bold "m" after the editor information, indicating a minor edit. Generally, minor edits aren't controversial or problematical. However, since editors—not the software—decide whether an edit is marked as minor (see the section about restricting your watchlist), an "m" isn't 100 percent guaranteed to be true.
- Towards the far right of each row is the edit summary. As discussed in the box about edit summaries, this text is how the editor describes that edit. Several things are worth noting:
- In the oldest edit in Figure 5-1, the editor went to some length (175 characters, to be exact) to explain the edit. The editor was probably concerned that other editors might think the edit was a mistake, and was trying to lessen the probability that the edit would be reverted (see the section about reverting).
- Two of the edit summaries include wikilinks (in blue) within the edit summaries. Wikilinks in edit summaries work the same way as wikilinks in articles, and you create them the same way (with paired square brackets around the page name). The same goes for piped links (see the section about links).
- In one edit summary, the words "Gubernatorial Legacy" are gray rather than black, with a right-pointing arrow in front of the text. As discussed in the section about editing a single section, if an editor selects only one section to edit, rather than the whole article, then the software inserts the name of that section into the edit summary's beginning.
- Finally, each row ends with an "undo" link. This link lets you revert the edit listed in that row. You'll learn how to use it later in this chapter (see the section about undoing).
Reading a page history—Making inferences
[edit]Moving from politics to movies, consider Figure 5-2, another screenshot of a page history, this time for the article on Clark Gable. Now that you know what all these little words and links represent, you can use them to get a sense of how the page has evolved over time. The page history gives you facts. You have to figure out what it all means.
![](http://upload.wikimedia.org/wikipedia/commons/thumb/b/b2/Wikipedia-The_Missing_Manual_0502.png/640px-Wikipedia-The_Missing_Manual_0502.png)
Reading the page history for the Clark Gable article, you'll notice the following facts and make some related inferences:
- The top six edits were done by the same editor. Sometimes that indicates inexperience: Wikipedia veterans often do some editing of a page, click the Preview button to see the change, do more editing, preview again, and so on, before actually saving the changes to create a new version.
- Or perhaps the editor was saving changes in small increments to avoid edit conflicts (see the section about edit conflicts). Working in small, incremental edits is a good idea when lots of edits are happening, on popular pages and pages about current events. In Figure 5-2, the information in parentheses (the edit summary) shows the editor worked on six separate sections, perhaps to make it easier for others to see what he was doing to a long-established article.
- For five of those six edits, the editor didn't offer much explanation in the edit summary (all he wrote was "copyediting"). Presumably, he thought that other editors wouldn't find the edits controversial, so there wasn't any need for lengthy explanations.
- The seventh edit was by an anonymous editor, not a registered user. For this edit, the "talk" link is red, indicating that this editor's user talk page doesn't exist yet. (If it did, the link would be blue, like the others.) User talk pages are one place where editors communicate with each other (see the section about user talk pages); only in very rare circumstances do established editors lack a user talk page. A red link is a red flag. It means this editor probably has very few edits, which greatly increases the likelihood that this edit is not constructive.
- The anonymous editor didn't explain what their edit was about. The edit summary has only the section name ("Most Famous Roles"). That's another indication that this person probably hasn't done much Wikipedia editing.
In the next section, you'll look at what actually changed with this mysterious edit. If you care enough about an article to take a look at its history, you probably want to take a peek at any such potentially questionable edits you come across.
Seeing what changed
[edit]Once you've got an overview of a page history, you can stop right there, or take it a step further—look at actual edits to see who changed what. If a glance through the page history doesn't make you suspect vandalism (for example, vandalism is unlikely if the last edit was more than a week ago, and by a registered editor with a user page and a user talk page), you can go ahead and edit the article without probing more deeply. But most of the time you're going to be curious about one or more specific (usually recent) edits, for one reason or another. In addition, when you're starting out, looking at others' edits is a good way to learn about how to edit Wikipedia.
Fortunately, you could pretty quickly go ahead and look. When you want to see what one or more editors have changed in an article, you ask the software to compare one version of the page against another version. The resulting output, the difference between versions, is the actual edit.
Looking at a single edit
[edit]Any single edit of a page is the difference between one version of a page (one row in the page history) and the version immediately before it (the row below it). You have two ways to get a diff for a single edit. The slow way is to use the two columns of radio buttons, and then click "Compare selected versions" (or press Enter). The fast way is to click the "last" link, on the left side of the version you're interested in.
Time to take a closer look at that anonymous edit in Figure 5-2 to see whether it was vandalism. When you click "last" on the row for the edit of 21:15, 12 February, you get something that looks like Figure 5-3.
![](http://upload.wikimedia.org/wikipedia/commons/0/07/Wikipedia-The_Missing_Manual_I_mediaobject5_d1e7223.png)
Here's how to read the various elements on a diff page:
- Your browser's address bar gives the output page's URL. When instructions on an administrative page say, "provide diffs," they're asking for URLs like this.
- Near the top of the output page is information about the two versions of the Wikipedia page being compared: the version just before the edit, and the version that resulted from the edit.
- The heart of the output page is the before-and-after comparison showing what text was added (nothing, in Figure 5-3), deleted (nothing), and what was changed (just one word). This side-by-side comparison is the actual edit.
- For context, the side-by-side comparison shows a paragraph or section heading immediately above the paragraph where the change was made, then the paragraph with the change, and finally the next paragraph or the heading of section below the change.
- When a word has changed, the software shows that word in bolded red for emphasis: in this case, "wife" (before) and "life" (after). So it turns out that the edit was constructive—it fixed an incorrect word that was a typo, Freudian slip, or somewhat subtle vandalism.
- At the bottom of the diff page is the article as it appeared at 21:15, 12 February (only part is shown in Figure 5-3, to save space). You may not even need to look at this article snapshot, but it can be helpful for figuring out things like exactly where an edit occurred within a long article.
Looking at multiple edits simultaneously
[edit]You now know how to see what changed in a single edit. But often you'll want to see what changed in a group of consecutive edits. For example, suppose you edited an article 2 days ago and want to see everything that's changed. If there were 10 edits since then, you would want to see, in one place, everything that's changed; you don't want to have to do 10 different diffs. Or suppose several different anonymous editors have edited an article recently. By looking only at the net effect of all the recent edits, you don't have to bother dealing with vandalism by one editor, if another editor has already fixed it.
To take Figure 5-2 as an example, suppose you want to see in a single place what editor John Broughton did in his six edits. You can view multiple edits simultaneously in one of two different ways: a quick way that works only in limited circumstances, and a slower way that works anytime. Figure 5-4 shows the tools for both options.
![](http://upload.wikimedia.org/wikipedia/commons/thumb/c/cf/Wikipedia-The_Missing_Manual_0504.png/329px-Wikipedia-The_Missing_Manual_0504.png)
If the 02:56, 13 February 2007 edit was the most recent, you can quickly see what changed in the six edits of interest in Figure 5-4 when you go to the row for the 21:15, 12 February version (the one just before the edits of interest), and click "cur". That click tells the software to compare that version to the current version; the difference between the two versions, of course, is the six edits.
The quick way's limitation, of course, is you can only use it when you're comparing the current version to a prior version—that is, you're looking at a consecutive group of edits up to and including the most recent. The quick approach doesn't work if you want to compare one old version to another old version of the article, to see what changed between them; for example, if an edit (according to its edit summary) fixed vandalism, but you suspect it didn't completely correct the vandalism of the immediately proceeding edit. If you can't use the quick way, the slower (but universal) way to see what happened in a group of consecutive edits is to use the two columns of radio buttons. In the first column, select the "before" version; in the second column, select the "after" version (Figure 5-4). Then press Enter or click "Compare selected versions".
Looking at a page's prior version
[edit]As mentioned earlier in the chapter, you can use a page history in three ways: Read it to get an overview, view and compare edits, or get to any prior version of the page. That third option is the least useful, since you can better figure out what's changed on a page by looking at the actual edits, but you can see what an article used to say at an earlier point in time if you really want to.
To see the text of any specific prior version of a page, simply click its time and date on the history page. Bear in mind that Wikipedia stores the text of a page version in its database, but doesn't keep a record of any images or templates that were on the page at that time. Instead, the software recreates a prior version of a page inserting the current image and templates into it.
In other words, you're not looking at an exact copy of an older version of a page, as it would have looked. But that usually doesn't matter, since it's almost always the text you're concerned about, rather than images or templates. (If you want to see what the image looked like at the time, click the image, which takes you to the history page for that image. Similarly, if you're concerned with the template, click it to go to the history page of the template to see what, if anything, changed before the current version.)
Reverting edits
[edit]If you're reading an article in Wikipedia and see vandalism, unencylopedic links to commercial or personal Web sites (linkspam), or some other blatant policy violation, your first impulse may be to click "edit this page" and fix the problem. Resist that urge. Manually deleting offending text is error-prone and time-consuming. And, worst of all, if the vandal or spammer deleted or overwrote text while doing the dirty deed, simply removing the problem still leaves the article damaged, since good information is now missing.
Instead, use options in the page history to revert the problematic edit(s). Reverting restores any content that was overwritten or deleted, and removes offending text, putting the article back to what it was before it was vandalized or spammed. Reverting is one of the most powerful features of wiki software. This section shows you how to do a revert in just a few easy steps.
Two options: Revert to a prior version and undo
[edit]There are two ways to revert an edit. The simplest is to change the damaged page so that the current version of the page was reset to an older, good version. If the last good version was, say, as of Wednesday at 10:00 UTC, then the software would essentially copy that version, overwriting all the changes (edits) made after that time and date.
For the majority of vandalism cases, this kind of revert is sufficient, because good editors check page histories for signs of likely vandalism before editing, and because anti-vandalism activities (which you can read more about in Chapter 7: Dealing with vandalism and spam) identify most vandalism shortly after it appears. But the major drawback of this approach is clear—what if one or more constructive edits came after the problem edit occurred?
The other option—undoing one or more consecutive edits that aren't the most recent—offers a way off the horns of that dilemma. It's usually possible (more details below regarding "usually") to get Wikipedia software to revert interior edits—ones that don't include the most recent edit. Unlike a revert, an undo retains good edits that occurred after the problem edit, creating a truly new version of the article.
To revert or to undo
[edit]Say you're looking at five edits of an article, one per day starting on January 1. The edits on January 4 and 5 were constructive; you want to keep those. The edits on January 2 and 3 were vandalism. The edit on January 1 was constructive, and there's no vandalism prior to that. Using the revert approach, you'd have to revert the article to the last good version (the one on January 1), and then manually add back the good edits of January 4 and 5. That would be the only way to avoid denying the readers of Wikipedia the good information and penalizing the editors who supplied it but missed the vandalism. In this case, you now can use undo to remove only the two vandal edits.
On the other hand, if you want to revert only the most recent edit, or the last few edits (say the edits from January 2 through the 5 were all vandalism), then you can use either revert to a prior version or undo. Both are four-step processes that take roughly the same amount of time. As a bonus, if you're reverting only one edit, the undo option has the advantage of automatically adding information to the edit summary.
So if undo works all the time, while reverting is useful only sometimes, why learn both processes? There's one advantage to using the classic revert: Unlike an undo, with a revert it's impossible to have an edit conflict (see the section about edit conflicts). If you're reverting vandalism on a high-traffic page (today's featured article on the Main Page is a prominent example), an edit conflict could significantly slow your fixing of some highly visible vandalism. So knowing how to revert can still be useful for relatively rare cases.
Option 1: Undo
[edit]Doing an undo is a four-step process, starting from the history page. (If you're starting from a diff page (see the section about diffs), then just skip step 1.)
1. Select the edit(s) you want to undo.
- If you're reverting only one edit, click the "undo" link (on the far right) of the problem edit's row. (This step saves you from having to click "undo" in step 2, by the way. If you clicked the "last" link, by contrast, you'd have to click "undo" in step 2.)
- If you're going to undo multiple consecutive edits, use the radio buttons (Figure 5-4) to create a diff.
2. On the diff page, click "undo" at upper right, above the right column of text (Figure 5-3).
- The Wikipedia software tells you whether it can revert the edit(s). The more consecutive edits you're trying to undo at the same time, assuming none is the current version, the less likely that the software can actually do an undo of the whole group.
- However, most of the time, if the span of edits you're trying to undo isn't too wide, you'll see the following message at the top of the page: "The edit can be undone. Please check the comparison below to verify that this is what you want to do, then publish the changes below to finish undoing the edit." If you see this message, you should take a quick glance at the comparison (two columns, just like Figure 5-3), and then skip to step 4.
3. If the top of the page reads, "The edit could not be undone due to conflicting intermediate edits", and you're looking at an edit window (don't start editing), then turn to Plan B:
- If you were trying to revert multiple edits at the same time, try doing them one by one, starting with the edit that changed the largest amount of text. You may find that you can still undo most of what was done improperly, even if you can't undo it all.
- If you were trying to revert a single edit, and the undo can't be done, then you're going to have to dive in and start editing. Click the Back arrow on your browser (or Back button on your keyboard, if you have one) to return to the diff. Then open the current version of the page (or current version of a section, if that's all that needs editing) in a different window, and use the diff as a guide to manually edit the current version.
4. Edit or add to the edit summary.
- If you undid only a single edit, you'll see an automatically generated edit summary below the editing window like the following:
- ([[WP:UNDO|Undid]] revision 132832143 by [[Special:Contributions/Name Of Editor|Name Of Editor]] ([[User talk:Name Of Editor|talk]])
- That intimidating text looks like the following when someone looks at the page history:
- Undid revision 132832143 by Name of Editor (Talk)
- Since the edit summary consists of a maximum of 500 characters, there's a limit to how many words you can add to the edit summary after the computer-added text (431 characters in this example, counting blank spaces—which do count). You have enough room to add, say, rvv (meaning "revert vandalism") or rv linkspam. If you're not reverting vandalism, however, then your undo may not be clear to other editors, and you should explain it in the edit summary. If you need more space, you can remove the link to the editor's talk page; in this example, delete ([[User talk:Name of Editor|talk]]). (Other editors can easily get to that user talk page via the second wikilink in the edit summary, the one to the user page.)
- If you undid more than one edit simultaneously, then the software doesn't put anything in the edit summary, so you need to. Be brief but clear; for example, rv multiple vandalism by two different users on 10 May, or rv three edits by Name of Editor—per Arbitration Committee decision, editor is not allowed to edit this page.
5. Below the editing window, click the "Publish page" button.
- Normally, clicking this button completes the undo. But you may get one of two error messages:
- If you've turned on "Prompt me when entering a blank edit summary" in the "editing" tab of your My Preferences page (see the section about edit summaries), you may see a message that the edit summary is blank, even though it's not. It's a bug: When Wikipedia's own software adds an automated edit summary, it sometimes doesn't know what it just did. If you do in fact have text in the edit summary field, just click "Publish page" again, and now you're done.
- If you get a message that you have an edit conflict, then someone edited and published a change to what was the current version, before you published yours. You can either repeat this four-step procedure again (more quickly, perhaps) or do a manual edit. (See the section about edit conflicts for a more detailed discussion of handling edit conflicts.)
Option 2: Revert to a prior version
[edit]Reverting to a prior version is appropriate only if, after looking at one or more edits, you decide that the most recent edit or edits should be reversed; for example, someone has just vandalized a page and the next-to-last version of the page is vandalism-free.
Doing this type of revert is a four-step process, starting from the history page:
1. Click the row for the last good version of the page.
- That's the version before the vandalism or spam occurred; the version you believe is the last good one. Click the time/date link in that row. You then see that version, with a warning near the top of the window (Figure 5-5).
![](http://upload.wikimedia.org/wikipedia/commons/thumb/6/60/Wikipedia-The_Missing_Manual_0505.png/640px-Wikipedia-The_Missing_Manual_0505.png)
2. At the top of the page, click the "edit this page" tab.
- Now you'll see a second warning, just a bit more prominent, as shown in Figure 5-6.
![](http://upload.wikimedia.org/wikipedia/commons/thumb/5/5d/Wikipedia-The_Missing_Manual_0506.png/640px-Wikipedia-The_Missing_Manual_0506.png)
3. At the bottom of the edit window, add an edit summary.
- You don't need to say much:
- The most common reason for reverting is vandalism, and the most common situation with vandalism is that you're reverting only the last edit, or only a series of edits by the same editor. If so, you need only to put rvv (which stands for revert vandalism) in the edit summary.
- If you're reverting for something other than vandalism, explain a bit; for example, rv linkspam.
- If you're reverting edits by more than one editor (for example, two different accounts vandalized the page, back to back), then mention which version you're reverting to—for example, rvv, reverting to version of 10:05 15 May.
4. Click the "Publish page" button.
- That's it—you're done.
After you fix a page
[edit]After you've undone or reverted an edit (clicked the "Publish page" button), it's a good idea to glance at the page to see if it reads the way you expect. If the undo or revert doesn't seem to have happened, refresh the page in your web browser; pressing Ctrl+R (⌘-R on a Mac) does the trick in most browsers. If the problem is gone, your revert was successful. Congratulate yourself for improving Wikipedia. If you do see some vandalism that you missed, then you can fix it with another undo, if possible, or by doing a direct edit if necessary.
Advanced techniques
[edit]Once you've mastered the steps in the previous section, you can revert or undo any edit on any Wikipedia page. You can lead a long, happy life without going any further. But if you devote yourself to lots of article repair and restoration, you may appreciate help from some power-user tools, like the three described next.
Customization
[edit]If you're an experienced editor who spends a lot of time looking at page histories, consider some customization to enhance the history display:
- The user script at User:Stevage/EnhanceHistory.user.js collapses consecutive edits from the same person into one. It also adds a button so that diffs show up on the history page rather than a separate page. (Chapter 21 provides details about getting a user script to work.)
- Another minor—but useful—customization often makes it much easier to locate what's been removed from or added to a page when the change involves just a period, comma, dash or other small single character. Add the following to your common.css page (which you'll probably need to create, as a subpage, per the instructions in the section about creating a personal sandbox):
.diffchange {padding: 0px 2px 0px 2px; border: 1px dashed red; margin: 0px 1px 0px 0px}
Automated identification of the editor of specific text
[edit]You may find yourself digging through a large number of prior versions of a page, trying to identify exactly who added a given bit of text, and when (for example, to find out if whoever added the text did anything else questionable at the same time). After scrolling through history pages and searching through a large number of versions of the page, you might think: "There has to be a better way." In fact, there is; you have two alternatives:
- An automated tool called WikiBlame, available at http://wikipedia.ramselehof.de/wikiblame.php, digs through the versions for you, spotting what you're looking for.
- Another alternative is to dump up to the last 100 versions of a page into a single document which you can then search. To do so, go to the Special:Export page, and follow the easy instructions there. When you do paste the contents of the export into a document, do so as unformatted text; that's faster.
Counting and sorting edits
[edit]Sometimes you'll want to know the names of the editors who did the greatest number of edits to an article, or other statistics about edits to a particular page. Wikipedia has a number of tools to count edits, sort edits by contributor, generate statistics about contributors to a page, and so on. Two places to start are:
- Article info. https://xtools.wmflabs.org/articleinfo/en.wikipedia.org
- Wikipedia Page History Statistics. https://vs.aka-online.de/cgi-bin/wppagehiststat.pl