Meta Refresh works in Preview and not in production

:wave: Netlify gurus

Our Gatsby blogging engine has been running for a year without issues. We now added code to implement meta refresh or unfurl and this seems to work very nicely in the Netlify preview but alas not in production on the custom domain as shown :point_down: .

Are there any suggestions where we might look to find this error.

preview
https://60ba02134dd2d200077a85d6–cranky-johnson-1489b1.netlify.app/blog/20210414_ms_story_diabetes_was_the_best_thing_that_ever_happened_to_me_donal

production
https://blogs.meterbolic.org/blog/20210414_ms_story_diabetes_was_the_best_thing_that_ever_happened_to_me_donal

Thanks for any tips
Eric

Hi @ericmsmythe,

I don’t see any meta refresh on either of those URLs. However, if you tell us what you’re trying to achieve, we might have some suggestions.

1 Like

@hrishikesh You beat me by seconds.

1 Like

Haha, sorry didn’t see anyone typing so jumped in.

1 Like

Thank you @hrishikesh for asking.

I am pasting an image in here that I hope will show the difference in the behaviour of the two URL’s viz preview and production

image

I am referring of course to the page preview when posting to a social media site or into a messenger.

Its puzzling how this works fine in the one case and not in the other.

Thanks for any help :pray:

Oh now I see what you meant. It’s not meta refresh, but og preview. Also, this isn’t the correct place to debug OG tags. Check the links here:

Preview is here

Production is here

That’s supposed to give you more accurate and correct information as to why it’s (not) working. As far as I can see, both the pages are loading a correct preview:

Preview:

Production:

So we can’t comment on why it’s not working in a particular application.

Super @hrishikesh

Following your clue, I tested on https://cards-dev.twitter.com/validator
And the custom domain did not return a card, no data and the preview did return an ideal preview.

We do have some issues, but I was wondering if there is some reason that both Telegram Messenger and Twitter card validator show that the custom domain build is faulty.

Also the google validator times out on the neetlify site, I guess we have to upgrade for more bw :wink:

Thanks again for the support
Best wishes
Eric

My apologies if I am harping on the question, but from a purely netlify domain perspective, should the html not be idential. Here is a dif fof the headers that shows differences. The production should be like the preview but it is not.

Many thanks again

Hi @ericmsmythe,

Testing with Twitter’s card validator returns ERROR: Required meta tag missing (twitter:text:title) e.g. <meta name="twitter:title" content="This is a really awesome page!">

The og:title on both the URLs is empty <meta data-react-helmet="true" property="og:title" content="">

Here are two OG/Twitter tag generators if you need/want to create a sample set Open Graph Generator | Web Code Tools / https://webcode.tools/generators/twitter-card and Open Graph Generator / Twitter Card Generator