How to properly index hstore tags column to faster search for keys
You could try indexing the keys like in the following examples and see how that works:

CREATE INDEX nodes_tags_key_historic_idx on nodes ( (tags-&gt;'historic') );
CREATE INDEX nodes_tags_key_tourist_idx on nodes ( (tags-&gt;'tourist') );
ANALYZE nodes;


What does your query plan look like when run with EXPLAIN ANALYZE?

[edit]: Alternative indexes:

CREATE INDEX nodes_tags_key_tourist_idx2 on nodes ( (tags ? 'tourist') );
CREATE INDEX nodes_tags_key_historic_idx2 on nodes ( (tags ? 'historic') );


The latter shouldn't require any changes to your query.