Tips, Tricks & Best Practices

HSalah
Contributor | Platinum Partner
Contributor | Platinum Partner

form directing to thank you page then url

SOLVE

hubspot provides the service of chosing between directing the user to a thank you page or directing the user to a url. Is it possible to do both ? I want after the form submission the user to be directed for 2 seconds to a thank you page then to be directed to a url

2 Accepted solutions
karstenkoehler
Solution
Hall of Famer | Partner
Hall of Famer | Partner

form directing to thank you page then url

SOLVE

Hi @HSalah,

 

Both are technically the same – in both cases, after the form submission you're sending the contact to a page.

 

If you want to automatically redirect a contact from one page to another after a certain time has passed, here's what you could do; with the help of generative AI:

 


1. HTML Meta Tag (Simple & Effective)

Place this in the <head> section of Page A:

<meta http-equiv="refresh" content="2;url=https://example.com/pageB.html">

2 is the delay in seconds.

Replace the URL with your destination.

 

2. JavaScript Redirect (More Control)

Place this script in the <head> or right before the closing </body>:

<script>
setTimeout(function() {
window.location.href = "https://example.com/pageB.html";
}, 2000); // 2000 milliseconds = 2 seconds
</script>

This method gives you more flexibility (e.g., conditionally redirecting, animations before redirect, etc.).


3. Using HTTP Headers (If Server-Side Control)

If you're generating Page A via a server (e.g., PHP), you can use:

<?php
header("Refresh:2; url=https://example.com/pageB.html");
?>

This is server-controlled and less common for frontend-only use.


Best regards

Karsten Köhler
HubSpot Freelancer | RevOps & CRM Consultant | Community Hall of Famer

Beratungstermin mit Karsten vereinbaren

 

Did my post help answer your query? Help the community by marking it as a solution.

View solution in original post

0 Upvotes
karstenkoehler
Solution
Hall of Famer | Partner
Hall of Famer | Partner

form directing to thank you page then url

SOLVE

@HSalah that's exactly what I described:

  1. Contact submits form
  2. Form settings redirect them to a thank you page ( = page 1)
  3. After 2 seconds, you want them to be redirected to another page ( = page 2)

Correct?

Karsten Köhler
HubSpot Freelancer | RevOps & CRM Consultant | Community Hall of Famer

Beratungstermin mit Karsten vereinbaren

 

Did my post help answer your query? Help the community by marking it as a solution.

View solution in original post

0 Upvotes
4 Replies 4
karstenkoehler
Solution
Hall of Famer | Partner
Hall of Famer | Partner

form directing to thank you page then url

SOLVE

Hi @HSalah,

 

Both are technically the same – in both cases, after the form submission you're sending the contact to a page.

 

If you want to automatically redirect a contact from one page to another after a certain time has passed, here's what you could do; with the help of generative AI:

 


1. HTML Meta Tag (Simple & Effective)

Place this in the <head> section of Page A:

<meta http-equiv="refresh" content="2;url=https://example.com/pageB.html">

2 is the delay in seconds.

Replace the URL with your destination.

 

2. JavaScript Redirect (More Control)

Place this script in the <head> or right before the closing </body>:

<script>
setTimeout(function() {
window.location.href = "https://example.com/pageB.html";
}, 2000); // 2000 milliseconds = 2 seconds
</script>

This method gives you more flexibility (e.g., conditionally redirecting, animations before redirect, etc.).


3. Using HTTP Headers (If Server-Side Control)

If you're generating Page A via a server (e.g., PHP), you can use:

<?php
header("Refresh:2; url=https://example.com/pageB.html");
?>

This is server-controlled and less common for frontend-only use.


Best regards

Karsten Köhler
HubSpot Freelancer | RevOps & CRM Consultant | Community Hall of Famer

Beratungstermin mit Karsten vereinbaren

 

Did my post help answer your query? Help the community by marking it as a solution.

0 Upvotes
HSalah
Contributor | Platinum Partner
Contributor | Platinum Partner

form directing to thank you page then url

SOLVE

No i don't just wanr to automatically redirect a contact from one page to another after a certain time has passed i want during this certain time a thank you page appears then to be redirected to the url page 

0 Upvotes
karstenkoehler
Solution
Hall of Famer | Partner
Hall of Famer | Partner

form directing to thank you page then url

SOLVE

@HSalah that's exactly what I described:

  1. Contact submits form
  2. Form settings redirect them to a thank you page ( = page 1)
  3. After 2 seconds, you want them to be redirected to another page ( = page 2)

Correct?

Karsten Köhler
HubSpot Freelancer | RevOps & CRM Consultant | Community Hall of Famer

Beratungstermin mit Karsten vereinbaren

 

Did my post help answer your query? Help the community by marking it as a solution.

0 Upvotes
HSalah
Contributor | Platinum Partner
Contributor | Platinum Partner

form directing to thank you page then url

SOLVE

@karstenkoehler correct