I want to create redirection URL for my wordpress website

I don’t know much about php, i have tried to find this question on stack exchange but I could not found.

what I am trying to do - here is my website websiteurl/ I want when someone write in url “websiteurl/?URL=anothersiteurl” it will redirect to the given “anothersiteurl” like how to write code and where to write code my website built on wordpress.

Hi there,

A quick search on Google for this question gave me some hits but this specific article seems to give multiple ways that you can try (just backup any file you are planning on modifying before trying them)

to be clarity I want something like this

Are you hoping to learn some coding (for eg javascript) to do this or are you hoping there’s a plugin that can do this for you?

If it can be done throug coding that would be great!!

i think the scope of the question is beyond the forum here, but you will probably need to learn about REST APIs (such as described here: REST API Handbook | Developer.WordPress.org ) and develop a plugin to do this work.