Wikidata Query Service/Implementation/Standalone

WDQS can be run as a service for any Wikibase instance, not just Wikidata. You can still follow the instructions in the documentation, with the following changes:

To generate the dump of your database, use  script in the   directory of Wikibase extension. Depending on your requirements, you may still want to run  script, or you may load the resulting RDF directly into the database.

You may also want to set  parameter when running Blazegraph if your ontology uses URIs that are not based on Wikidata URIs, e.g.: And the same option for Updater.

Required setup
So far, the following conditions should be fulfilled by Wikibase instance for WDQS to work properly: Given Wikibase install top URL as ,
 * RecentChanges API should be accessible at
 * Entity data dump should be accessible at  for entity.

If your Wikibase instance has different URL scheme, the recommended way is to create web server redirects for these two, as these parts are not customizable yet. See below about the URL customization.

You can also separately set Wikibase entity concept URL. The assumptions are, given base URL as :
 * The entity prefix is
 * The data prefix is

You can verify those looking at  and   prefixes in the entity dump URL above, e.g. https://www.wikidata.org/wiki/Special:EntityData/Q4.ttl