Redirects removed games from the Steam store to SteamCommunity or SteamDB.

Install

Configuration

Go to https://steamcommunity.com/?ssr=wizard to run the settings wizard. This wizard allows you to change the redirect between SteamCommunity and SteamDB (default is SteamCommunity).

How does it work?

It appends the hash '#app_[steamId]' or '#sub_[steamId]' to all of the store links in the page. This way, when you open a link and the game has been removed from the store, you are redirected to the main store page, but the hash remains in the URL, allowing the script to detect that the game has been removed and redirect you to SteamCommunity or SteamDB.

If the game has not been removed, the hash is removed from the URL, for cosmetic purposes.

It also keeps observing the page, so that it can append the hash to any links added dynamically.

Examples

After installing the script, you can test it on the links below:

Source: https://rafaelgssa.gitlab.io/monkey-scripts/steam-store-redirector

6 years ago*

Comment has been collapsed.

Shouldn't "Redirector" be more appropriate?

6 years ago
Permalink

Comment has been collapsed.

Hm, I used "redirecter" in ESGST all this time and no one corrected me so I didn't even notice. Thanks.

6 years ago
Permalink

Comment has been collapsed.

Eh, I usually don't nit-pick, but I thought you'd like to correct it while the thread/script is still "fresh". ^^

6 years ago
Permalink

Comment has been collapsed.

Let's change it to rediREKTor xD

6 years ago
Permalink

Comment has been collapsed.

xD

6 years ago
Permalink

Comment has been collapsed.

// @include *

Is that really a good idea?

6 years ago
Permalink

Comment has been collapsed.

I don't know, is the use of include a bad thing? The script's supposed to run everywhere, so I didn't think match would be appropriate.

6 years ago
Permalink

Comment has been collapsed.

Replaced it with match, I wasn't aware of the insecurities of include.

6 years ago
Permalink

Comment has been collapsed.

insecurities

huh, is it?

supposed to run everywhere

I meant that. Scanning through all links on every page no matter how unrelated seems somewhat excessive.
Isn't limiting it to sg,steam enough?

6 years ago
Permalink

Comment has been collapsed.

Well, at least here it says "match" is safer.

It's not like the script is heavy, it won't affect the performance in the page. I personally would want to be redirected from anywhere. If you don't, just edit the "match" fields yourself to the pages that you want it to run on.

6 years ago
Permalink

Comment has been collapsed.

says "match" is safer.

sounds more like it is better in limiting matched urls, not safer in security sense

won't affect the performance

perf here is bad enough to care about everything ;-)

6 years ago
Permalink

Comment has been collapsed.

I wasn't talking about security in that sense. :P

6 years ago
Permalink

Comment has been collapsed.

I personally would want to be redirected from anywhere. If you don't, just edit the "match" fields yourself to the pages that you want it to run on.

I modified mine to only work on the places where I click on Steam URLs the most:

// @match *://*.steamgifts.com/*
// @match *://*.steamtrades.com/*
// @match *://*.steampowered.com/*
// @match *://*.steamcommunity.com/*
// @match *://*.reddit.com/*
// @match *://*.google.com/*

6 years ago*
Permalink

Comment has been collapsed.

I have a question about coding style.
I see you use " --i " but why use with " i >= 0 " not " i > -1 " to get maximum ultra special performace?
(This may be an unnecessary question but I didn't see this combination usually.)

6 years ago
Permalink

Comment has been collapsed.

Hmm, interesting, I never really thought of doing it that way, although I'm pretty sure the gain would not be noticeable at all. I'll change it later.

6 years ago
Permalink

Comment has been collapsed.

I didn't know about Violentmonkey. Have you tried it? Is it good? Does ESGST work well with it?

6 years ago
Permalink

Comment has been collapsed.

I tried it once just to see if ESGST loaded fine, and it did (although I didn't test all features, so I can't confirm if it works 100%), but I didn't use it long enough to get a good feel on it. I added it to the list because usually Chrome users go for Tampermonkey, Firefox users go for Greasemonkey and Opera users go for Violentmonkey, so I think those are the 3 main ones, but there are a lot other userscript managers around.

6 years ago
Permalink

Comment has been collapsed.

Btw for me on Firefox/GM the bar above the posts in the thread hasn't been working at all for many months. It used to have a button to mark all posts read and another to go to the first unread post, but neither has been functional in a few forevers.

6 years ago
Permalink

Comment has been collapsed.

Why wait months before reporting?

6 years ago
Permalink

Comment has been collapsed.

Because back then it was "I don't feel like supporting GreaseMonkey / Firefox users" (IIRC some realtime data sync between tabs did not work). Right now the OP lists GreaseMonkey as a supported userscript manager and you also just mentioned Firefox users as individuals permitted to breathe in the post I replied to.

6 years ago*
Permalink

Comment has been collapsed.

Deleted

This comment was deleted 3 years ago.

6 years ago
Permalink

Comment has been collapsed.

It supports endless scrolling.

Where? What can be scrolled when a script redirect me from a page to a page? I don't understand it at all.

6 years ago
Permalink

Comment has been collapsed.

I mean if you're on a website that has endless scrolling, links to the Steam store that are added to the page later on are also modified.

6 years ago
Permalink

Comment has been collapsed.

Oh, I see. Thanks. Can you please post an URL to a removed steam page? I want to try it.

6 years ago
Permalink

Comment has been collapsed.

These are the ones I remember from the top of my head:

6 years ago
Permalink

Comment has been collapsed.

It works, thanks. But why the special URLs?

6 years ago
Permalink

Comment has been collapsed.

It's what the script does. It adds "#app_ID" or "#sub_ID" to the end of all links to the Steam store, so that if the page is redirected, the hash remains in the URL and the script is able to detect that the game has been removed.

The way ESGST did it was by using a local storage, but that doesn't work in most cases (for example, when right clicking the link and opening it in a new tab), so this is the best way to do it.

6 years ago
Permalink

Comment has been collapsed.

Yeah, I am very happy it supports also middle click. :) It's ok with the URL, I was afraid that people have to write the URLs like that. It's no problem when the script adds it. Good work.

BTW the script already have 3 Stars on Github. It seems to be quite popular even now. :)

6 years ago
Permalink

Comment has been collapsed.

Nah, that would be an awful way to do it. :P Only downside is if you copy a link it will retain the hash.

6 years ago
Permalink

Comment has been collapsed.

The copying should not be problem but it could be fixed, anyway, couldn't be? If you were bored one day... :)

6 years ago
Permalink

Comment has been collapsed.

I'll do some research, but I don't think it could.

6 years ago
Permalink

Comment has been collapsed.

You could probably also make a head request when a new URL is added (or first mouseenter, ...) and change href if reply indicates missing game page. As your script runs at document-start I guess there is not much difference in speed.

6 years ago
Permalink

Comment has been collapsed.

I'd rather not make any useless requests. If there are a lot of URLs in the page, that could extremely slow things down.

6 years ago
Permalink

Comment has been collapsed.

Yeah, that's why I added first mouseenter. Or perhaps first click? But yeah doing it for every link wouldn't be that great :D
Also of course filter by valid href first.

6 years ago
Permalink

Comment has been collapsed.

I don't like the idea of making any requests at all.

6 years ago
Permalink

Comment has been collapsed.

Okay :)! Great idea for a script btw.

6 years ago
Permalink

Comment has been collapsed.

It doesn't work
Firefox and Greasemonkey.

6 years ago
Permalink

Comment has been collapsed.

I just tested on Firefox with Greasemonkey and it works perfectly fine. Could it be because of the "include" if you are on v1.0? Try v1.1.

6 years ago
Permalink

Comment has been collapsed.

I don't know why, but now it seems to work, however... I think that the link in OP changed for the erased games...

6 years ago
Permalink

Comment has been collapsed.

It's supposed to change for all links.

6 years ago
Permalink

Comment has been collapsed.

It cleans the URL in the Steam Store page if there was no redirection.

I notice that for some reason, it leaves a "#" symbol on the end of all unredirected links. It didn't seem to do that yesterday, but does today.

6 years ago
Permalink

Comment has been collapsed.

Yeah, I don't think it's possible to remove that symbol. Usually Steam removes it when they redirect it.

6 years ago
Permalink

Comment has been collapsed.

Does the script need to match all urls?

6 years ago
Permalink

Comment has been collapsed.

Like I said in previous comments, it doesn't need to, but it should, if the script is to be fully effective. And the script is not heavy nor malicious, so there's absolutely no problem in it matching all URLs, but if you don't like that, you can change it manually like another user did, I'm not going to limit it officially.

6 years ago
Permalink

Comment has been collapsed.

Bump

6 years ago
Permalink

Comment has been collapsed.

New version up.

5 years ago
Permalink

Comment has been collapsed.

Really useful script! It's nice to no longer need to do it manually :)

5 years ago
Permalink

Comment has been collapsed.

Released a new version that has some improvements, if anyone still uses it.

3 years ago
Permalink

Comment has been collapsed.

👍

works fine, thanks!

3 years ago
Permalink

Comment has been collapsed.

You're welcome!

3 years ago
Permalink

Comment has been collapsed.

just found out about ti. tho duno if im doing it right? i installed it, go to that wizard link, enter 1 for steamdb, test it and still go to the steam home page

3 years ago
Permalink

Comment has been collapsed.

Does a hash get appended to the link? Like this: http://store.steampowered.com/app/91310#app_91310

3 years ago
Permalink

Comment has been collapsed.

oh, just tried again and seems like it works now. should link to the steam hub page for the game right?
https://i.imgur.com/8TrjPps.png

3 years ago
Permalink

Comment has been collapsed.

Well, if you configured it to redirect to SteamDB, it should be redirecting to SteamDB, not SteamCommunity.

3 years ago
Permalink

Comment has been collapsed.

i see, just tried again and yup, got it. thanks lol. is a great script

3 years ago
Permalink

Comment has been collapsed.

You're welcome.

3 years ago
Permalink

Comment has been collapsed.

Deleted

This comment was deleted 3 years ago.

3 years ago
Permalink

Comment has been collapsed.

Sign in through Steam to add a comment.