When we edit Wikidata we often come across duplicates. These can be caused by ingestion scripts running without checks, or editors adding items without investigating whether another item for the same entity already exists.
Of course, there will also be items with the same or similar labels (or names) which identify different things. Think apple and Apple, or indeed Apple. But in this case we are speaking about the same ‘thing’.
At the time of writing we have three Wikidata items for Marine Scotland. That is three items with their own QID each of which claims to be for the same entity.



Of course, by the time you read this blog post these three will now be one. So how do we do that?
We don’t generally delete wikidata items, since other items may point to them. What we would generally do, including in a case like this is merge them into one. By doing so redirects are put in place, meaning that any other items pointing to any of these three will point to the new merged site.
How to merge items
To merge items we need an extension called ‘Merge’. To obtain it click on the Preferences tab at the right of the wikidata page.

Then click on Gadgets on the ribbon menu.

Finally click on the check box next to Merge, under the Wikidata-centric heading.

Don’t forget to save your changes. You will be returned to the Wikidata item. You may need to refresh the page. Hover over the More link to the left of the search box at the top right of the page. You should see something like this with two drop-down options:

You’re now all set.
Open the items in separate tabs, or note the QIDs of the two (or more) items that require merging. I usually copy the QIDs to a text editor so I can retrieve them without retyping. I’ll grab the QID of the ‘best’ item, then go to the less good item. On the latter, click on Merge with.
You’ll get this dialogue box.

Enter the QID of the best one into the Merge with text field, and you uncheck the “Always merge into the older entity”. The latter is the default and depending on the result you want, you can end up with the QID of the newer, or inferior, item being used. It’s not critical, as we will see.
Click the blue Merge link (top right of the dialogue box) when you are ready.
The two items will now be merged into one, which will be loaded on screen. All links to that item will continue to work, and all to the now vanished item will point to the sole existing item instead,
If you have a third item repeat the process until you have one item left.
You may need to do a little tidying when you have completed merging. Carefully examine the new item – labels, descriptions and aliases in particular. But also check for duplicates, or even competing claims in other fields. Resolve these as well as you can.
You’ve now completed merging, and have provided a valuable service to to other Wikidata users!





