Questions tagged [301-redirect]
Using HTTP 301 Redirect
94
questions
0
votes
1
answer
16
views
unable to save a rewrite
Im trying to save a new redirects into the urlrewrite model but it seems that save() doesn't exist in those factorys:
Magento\UrlRewrite\Model\UrlRewriteFactory or
Magento\UrlRewrite\Model\...
0
votes
0
answers
14
views
Why magento generates two 301 redirections after product name change
I have a problem with 301 in magento 2.4.2. When I change the name of product, magento generates pernament URL redirects. Two of them, have you guys have any ideas why this is happening?
1
vote
2
answers
28
views
Weird 301 redirect for the entire site
I've made a copy of a Magento folder to set up another domain, swapped the old domain name both in the database (web secure url) and in the filesystem (env.php), and pretty much everywhere I could ...
0
votes
1
answer
30
views
how to solve temporary redirect in magento 2.4.3
I am the owner of the jewelry site when I run a Site audit from Semrush I get 944 temporary redirects, and I do not know how to solve temporary redirects in Magento 2.4.3
Please help
0
votes
1
answer
208
views
How to rewrite url with query string in magento 2
I want to rewrite url like:
https://www.test.com/custom-parent-cat/sub-cat/10-12-14-17-19.html?cat=101
to
https://www.test.com/custom-parent-cat/sub-cat.html
Please help me to achieve this.
Thanks
0
votes
1
answer
236
views
Proper way to remove .html extensions from URL and do a global redirect
I know how to remove.html extensions from URLs in Magneto 2.3, but I'm unsure what other steps I need to take to make sure I do everything properly.
I found that I should also create a global redirect ...
3
votes
2
answers
468
views
Multiple URL Rewrites for the same product is SEO issue?
By default in Magento, while assigning categories to the product. The Magento itself creates a URL rewrites based on each category which all going to be redirected to same product page.
Different ...
0
votes
1
answer
316
views
Redirect 302 into 301
in our magento application we have somehow a 302 redirect from /customer/account into /connexion. I would like to change it into a 301 one. No idea how to process this.
This seems to be handled in a ...
0
votes
2
answers
1k
views
ERR_TOO_MANY_REDIRECTS magento admin
After enable https, magento store works as expected but magento admin dashboard gives this error.
0
votes
1
answer
140
views
How to add 301 Redirect pages in magento 2?
I want to add 301 redirects to these URLs -
1-> From www.abc.com/blog To www.abc.com/blog/
2-> From www.abc.com/contact To www.abc.com/contact/
3-> From www.abc.com/catalogsearch/advanced To ...
0
votes
0
answers
427
views
Magento2 How to redirect category url to external link?
I have a requirement wherein I need to redirect multiple categories to external site's respective category pages.
For the same I have created categories in magento. Whenever we create a category in ...
0
votes
0
answers
73
views
Magento 1.9 - Varnish, nginx and redirects (http -> https and non-www to www)
trying to redirect all non-www traffic to www and all http traffic to https.
Environment is Magento 1.9 with Varnish and nginx. We also have Cloudflare (fully SSL enabled). Using the code below in ...
0
votes
1
answer
2k
views
Magento 2: URL Rewrite not working through .htaccess
I want to redirect some old URL's to new URL's I'm doing it in my .htaccess path: /root/.htaccess
<IfModule mod_rewrite.c>
############################################
## Enable rewrites
...
0
votes
1
answer
489
views
Magento 2 : Old product url to new product url redirect
Create a few new products. And set a URL for it (test1, test2, test3, etc.)
Change the URL via CSV import of that product (SKU, url_key) .. (change to 10test, 11test, 12test, etc)
. When using the old ...
0
votes
2
answers
191
views
Redirect to checkout from custom observer
I need to redirect to checkout from an observer related to the event customer_account_edited.
Here is my code. I've deleted a lot of rows that actually works...
Magento is doing everything well but ...
0
votes
1
answer
532
views
301 Redirect the Out of Stock Product Pages
Want to redirect for the products who are out of stock to custom url
Had tried below url but it did not helped
https://stackoverflow.com/questions/4824072/magento-out-of-stock-product-seo-problem
1
vote
1
answer
931
views
Nginx redirect for -only- homepage of old domain, to homepage of new domain
On the server.rewrites file within the nginx/ map, I have the following logic for redirecting the homepage of an old domain, to the homepage of a new domain:
if ($http_host ~ ^(www\.)?olddomain.com ) ...
1
vote
1
answer
791
views
Redirect 301 removing parameters in URL by .htaccess
In the file .htaccess in magento, I want to redirect a url with parameters. An example is this:
https://example.com/presente/decoracao/teu-sorriso?PageSpeed=noscript
I need to redirect this to the ...
1
vote
2
answers
2k
views
301 Redirect Multiple Url using .htaccess Magento 2
I'm trying to 301 redirect multiple urls to new url.
Using .htaccess File.
What changes i have to make in .htaccess
0
votes
0
answers
868
views
magento 2 how to redirect disabled product to category page?
I want to redirect disabled products to the related category page. I have tried discontinued option which is available in admin but it is not working.
How can I fix the issue?
0
votes
1
answer
1k
views
Rewrite rule for media images
we need to set rewrite rule for some images in Magento 2.2.5 using .htaccess rules or nginx conf
Example 1
Request Path:
https://www.example.com//media/catalog/product/cache/1/thumbnail/543x403/...
1
vote
0
answers
31
views
Setup automatic product redirect once out of stock on M1
Is there an extension/module for M1 Enterprise that will manage redirects to a suitable category page once a product is out of stock and won't come back into stock?
1
vote
1
answer
32
views
.htaccess redirect samplesitex.com to samplesitey/alias-page in both https and http variants
I am trying to redirect an alias url to a different url path. (it wont let me do this in cpanel for some reason)
Example:
SiteX.com > SiteY.com/this-page
I have tried
RewriteCond %{HTTP_HOST} ^...
1
vote
0
answers
50
views
Magento 2: To set 301 URL in Magento URL rewrites for this particular search
How to set 301 URL in Magento URL rewrites?
From
https://www.example.com/catalogsearch/result/?q=%7Bquery%7D
To
https://www.example.com/catalogsearch/result/?q=query
I have tried with below ...
0
votes
1
answer
138
views
Rewrite Rules to revert URL structure?
I've got a site which at some point in the past used SEO friendly category pagination for example :
category/subcategory/40.html
category/subcategory/4.html
category/subcategory/15.html
category/...
1
vote
2
answers
7k
views
Magento 2.2.5: Admin login page redirect loop 301/302 after installing SSL and enabling HTTPS
Preconditions
Ubuntu 18.04 DigitalOcean droplet
Nginx 1.1.4
MariaDB 10.1.34 (MySQL 15.1)
PHP 7.1 (Using FPM)
Redis server 4.0.11
Steps to reproduce
Download Magento 2.2.5 via Composer
Install ...
2
votes
1
answer
1k
views
Magento 2 with Varnish sometimes does not redirect HTTP to HTTPS
Our Magento 2 is setup with https on all pages (unsecure and secure, "use secure on frontend", etc.).
However sometimes when I enter ourdomain.com it redirects (correctly) to https and sometimes it ...
1
vote
1
answer
447
views
Blocking RSS Brute Force 1.9
I noticed this weekend that someone was pounding on /rss/catalog/notifystock/ trying to brute force the admin credentials. I've added a line to the nginx vhost.d conf that returns 403 when you attempt ...
0
votes
1
answer
199
views
Http to https 301 redirect
I am trying to enforce https on an existing magento website, so far so good, the website gets always correctly redirected to the https URL configured in the backend.
As of my understanding the ...
0
votes
1
answer
322
views
File not found. After adding 301 redirect - Magento 2
I've added a permanent 301 redirect to my Magento 2 store to remove .html
from my category and product urls by adding the following code to my website .conf file - I'm using Apache
redirectMatch 301 ...
0
votes
1
answer
543
views
301 redirect for multi website and store code added to url
I have a specific scenario to work with and need help.
Currently I have set up for 8 years a Magento 1 multi website store with this configurations:
Magento is installed in a subfolder of a domain ...
0
votes
1
answer
601
views
How to do redirect in Magento 2
I want to redirect to specific page.
I have created one script for testing but its not working. I am unable to redirect to another website url.
try {
require_once __DIR__ . '/app/bootstrap.php';
...
0
votes
1
answer
157
views
If request path is already exist what should i do for redirecting url with 301?
How to rewrite URL with 301 redirecting if request path and id already exist.
There is any other option to do that or can we do with .htaccess file?
1
vote
1
answer
1k
views
Domain redirection in htaccess not working
I have changed domain on the Magento store, however I need to still keep old domain urls accessible and redirected to new domain urls.
for example.
old-domain.com/products should redirect to new-...
0
votes
3
answers
1k
views
M2: How to redirect contact form page to CMS page
I tried to 301 redirect contact form page URL to custom cms page URL with Magento 2's rewrites, but it does not seem to redirect the URL for some reason.
Is there some special trick to be done with ...
3
votes
2
answers
1k
views
Magento: Delete products and 301 redirect to relevant it's parent category
Anyone have a solution for 301 permanent redirects for deleted products in Magento?
I have a store with 5000 products. 4000 have been sold and will never be back in stock. I want to delete those ...
1
vote
2
answers
854
views
How to redirect users to specific page when they go to any pages?
How to redirect customers to custom page when they go to any other page.
I have integrated OTP verification, I want to redirect customers to the verification page if they are not verified.
3
votes
2
answers
1k
views
Best practices of 404 product page redirection in magento
We have so many product which are no longer there in our website, but they are already crawled in google. I need to know what are the best practices to redirect them to any other page or something, ...
0
votes
2
answers
102
views
HTTPS 301 redirecting to http version
We have implemented https on our Magento store a few months back and
everything seems fine exceptive noted that the server response for 301
redirects don't seem to be honoring the https://
...
0
votes
2
answers
7k
views
How can I programmatically perform a 301 redirect in Magento 2
Today I am trying to redirects 301 pro-grammatically. But I have problem from
$this->_responseFactory->create()->setRedirect($CustomRedirectionUrl , 301)->sendResponse();
line. I have ...
0
votes
1
answer
34
views
Migration from Squarespace to Magento Addressing 301 Redirects on Mass
Long story short, we want to add only .html at the end of every category for the purpose of 301 redirects.
So an old category in Squarespace is like below:
www.domainname.com/categoryname
And in ...
0
votes
3
answers
55
views
Redirects and SEO
We have a category that we make available for approximately 2 weeks every 2 months for a presale. Once the presale is finished I redirect the category to another using a custom redirect.
What sort of ...
1
vote
0
answers
122
views
export enterprise url redirects
I am trying to export all my URL redirects from my Enterprise Magento instance. Is there a way to do this in the Admin or a SQL statement I can use to export it as a CSV? I am unable to find it in the ...
0
votes
1
answer
1k
views
Magento 2: Mass 301 Redirects for 404 Pages
I have a need in magento2 in Extension create like magento1 Mass / Bulk Redirects (301, 302, or any status) for Magento 404 Pages.
0
votes
1
answer
282
views
301 Redirect links from old categories to the new categories
I moved my website from Opencart to Magento and also renamed all categories.
So now I do have a lot of broken links that I would like to redirect to their new categories.
For example I have :
https:/...
1
vote
1
answer
9k
views
Redirecting HTTP to HTTPS?
I've read into this quite a bit but can't seem to find a solution. I'm trying to set it so whenever someone visits a link for my site (and for whatever reason they don't include https it redirects to ...
1
vote
0
answers
298
views
Cloned site still going back to old url
Okay, I have two domains pointing towards the one server a '.com' and a .cymru.
At first the .cymru domain was the main domain and .com the alias for it and I want to make the .com the main domain. ...
0
votes
1
answer
123
views
home URL Key Redirect
I recently notice google is indexing my site one with /home and one without. clearly this www.test.come/home URL exist but i do not see this url in my URL rewrite in the back-end. what is the best ...
0
votes
1
answer
264
views
How to redirect a link to another link 2 in magento
I have a blog page on this URL: http://159.203.70.155/index.php/blog/ and another page that have the same contents but different URL as this http://159.203.70.155/index.php/education-center.
Now i ...
3
votes
3
answers
5k
views
Magento 2: Bulk 301 rewrite imports
Read this great reference for creating a csv for import but this was for Magento 1
and it states you only need store_id, id_path,request_path, target_path, options but these headers won't work for ...