R
R
rowd2019-05-01 23:13:01
URL Handling
rowd, 2019-05-01 23:13:01

How to set up a 301 redirect from a folder to a subdomain?

How to set up a 301 redirect of all pages from a folder like domain.ru/folder to sub.domain.ru? As I understand it, an entry is made in htaccess, but what entry?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
Syomka Gavrilenko, 2019-05-01
@rowd

add to .htaccess file

RewriteRule ^subdirectory/(.*)$ https://subdomain.domain.com/$1 [R=301,L,NC]

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question