Feature #502


Create a user configurble URL modification

Added by GNU User almost 5 years ago. Updated 4 months ago.

Start date:
Due date:
% Done:


Estimated time:


(finally able to activate my account)

I would see as a good feature to have URL manipulation done automatic by the browser, based on domain rules.
Case in point, Invidious

It could turn this:
into this:

which would make it possible to, without using cookies or javascript, always have invidious play only the sound and start playing on its own. Other options are available this is only an example. I also think other websites might have some tweaks that would be interesting to use this feature.
Also, I see it as a fitting feature for the 3.x version, since the browser already does URL manipulation (to remove facebook tracking and such). Meaning it would hardly require Privacy View. Please correct me if wrong.




domain redirection.png (71.1 KB) domain redirection.png And then show it in this way ask low, 03/12/2024 02:51 PM
Actions #1

Updated by Soren Stoutner almost 5 years ago

  • Subject changed from Allow URL modification automatically by domain to Create a user configurble URL modification
  • Assignee set to Soren Stoutner

Currently there are only a few preset URL modifications, and all of them remove sections of the URL. I can envision a lot of good reasons to provide for user created URL modifications, like the one you mentioned above. These would allow for both adding and removing sections of the URL, and could be domain specific.

Note that this gets quite complicated rather quickly. Beyond building a user interface to allow users to create and manage these modifications, there are also considerations about how to apply these to URLs, what to do if there are multiple modifications being applied at the same time (when there are both additions and deletions), and controlling if they are applied to resource requests as well as base URLs. All of these are surmountable problems, but it means that I will likely push this off until near the end of the 3.x series.

Actions #2

Updated by GNU User almost 5 years ago

You are right in that this, apparently simple feature is quickly turned into a complicated mess when one starts thinking about all the possible URL modifications that the end-user might try to apply. So, I suggest thinking about the simple first steps to begin with.

Removing URL part: basically when that string is located in the URL, it is removed. It is up for the end user to be careful deciding what has to be removed.
Replacing URL part: whenever a certain string appears, it is replaced with another string.
Adding URL part: since we already covered "replacing", adding means basically at the end of the URL add some other string. It could also be done at the beginning of the URL, but maybe start with the end for now.

The same code used for removing Facebook tracking could be used to remove ANY part of the URL string and it shouldn't give any trouble (like I said, it's an advanced feature that leave up to the END USER the responsability of what he is deleting and wether or not the URL will load after).
All this would be a simple extra menu in the "Domain settings" in which you could have "add string" "remove string" and "replace string" options. For a start maybe have only ONE option available for a domain, at the same time.

Of course it's easier to say that do, but I hope this at least shows a clearer path of logic as to how this feature should work (for now at least, of course in the long run one could expect to use wildcards and such, but starting small and simple should help a lot).

Actions #3

Updated by Soren Stoutner over 4 years ago

This is a general implementation of the specific feature described at Likely one interface will be able to handle both.

Actions #4

Updated by Soren Stoutner over 2 years ago

There is also some discussion of this topic at

Actions #5

Updated by राही अखेराजोत about 2 years ago

Allow user to use split, replace/replaceAll, slice, splice etc methods. Add this option to Domain list.

Actions #6

Updated by Soren Stoutner about 2 years ago

I am not sure I understand what you are requesting. However, I should make two points.

1. This feature request is about URL modification, not Domain Settings. If you are referring to Domain Settings, you should create a new feature request.
2. For performance reasons, I am unlikely to implement anything that would require processing regular expressions. Some of the words you are using make me think that perhaps you are requesting something that would fall into that category.

Actions #7

Updated by ask low 12 months ago

Is this feature request for Link Redirection ?

Actions #8

Updated by Soren Stoutner 12 months ago

Yes, that is one of the things this will be able to do.

Actions #9

Updated by ask low 12 months ago

The most basic use case for me, is to redirect YouTube videos to piped. An URL typically<video-id> should redirect to<video-id>. Same goes to other sites. But this is the basic usecase I'm familiar with.

Actions #10

Updated by Soren Stoutner 12 months ago

This feature will be able to do that.

Actions #11

Updated by ask low 4 months ago

I've recently started relying on libreddit for reddit too. Everything from the reddit URL is same, except the base domain part.

For example: > >

by keeping the root uri same.

Actions #12

Updated by Soren Stoutner 4 months ago

That's exactly the type of modification this feature will allow.

Actions #13

Updated by ask low 4 months ago

Maybe introduce this into Domain settings itself. I think it would be a good idea. Just add a textbox for redirection link.

Actions #14

Updated by Soren Stoutner 4 months ago

This needs to be separate from domain settings because it can modify the domain, which could change which domain setting would apply. Doing this in domain settings could easily result in endless loop problems.

Rather, this will be a separate setting that will be applied before domain settings.

Actions #15

Updated by ask low 4 months ago

We can actually call this as Domain Redirection too. For instance, you can place this at the top of the Domain settings. If set up, grey out all the rest of the configuration for that domain.

Actions #17

Updated by Soren Stoutner 4 months ago

That wouldn't accomplish all this feature request needs to do. I think it is best to leave URL modification as a separate interface.

Actions #18

Updated by ask low 4 months ago

It makes sense for a full fledged implementation of this. But just reminding you that this'll become a very jumbled up situation.
Modify in the sense how ? The author is asking some crazy modification like adding &listen=1&autoplay=1 at the end. This is complicated because it should only be applied if watch? exists. And it's just one example.

I don't think this'll be helpful to anyone and too niche to even begin with. Setting aside #844 to be a very simple FR that tries to achieve a basic thing which is also a very important function to a lot.


Also available in: Atom PDF