How can I get a referer header for custom funding/sponsor links?

Hello,

I’m working on a simple tool to allow maintainers to redirect to dependencies’ sponsor links called payitfwd.dev

How it is meant to work is the maintainer adds the custom funding link https://payitfwd.dev which will then use the “referer” header to parse through the dependencies of the project to redirect the would-be donator to the sponsor page of a randomly-selected dependency maintainer.

Yes, I know referer cannot be relied on 100% due to some browsers disabling it by default, etc. In these cases a random small maintainer will be selected.

My question is, why are all official funding platforms allowed the referer header whereas the custom links are not allowed the same header? Each custom link has a rel="noopener noreferrer" html tag.

If there is no fundamental reason for this, can you enable headers for custom links? This would make payitfwd.dev a complete no brainer to implement for maintainers.

If it’s not feasible to enable referer for all custom links, can you provide an explanation and some instructions on how I go about getting payitfwd on the list of supported funding “platforms”?

Thanks in advanced

I’m not a GitHub employee.

It sounds like you’re working on something cool!

One of the reasons I can think of is the same reason some browser vendors disable the header (as you mentioned in your post): privacy. I wouldn’t count on this ever to start working.

For now, one concrete recommendation I can make is to ask users to fill in where they came from. I know that’s probably not the user experience you have in mind, but I can’t think of a more elegant solution.

on how I go about getting payitfwd on the list of supported funding “platforms”

I’m not sure how this works, actually!

Hi thanks for your reply.

I would also consider this a dead end of other officially supported links didn’t have the referral header but they do. Only custom links are explicitly not allowed the header.

It would be good to know exactly why this is.