# Support Single Page Application navigation logic in CTA (Beta) triggers

**URL:** <https://community.hubspot.com/t/support-single-page-application-navigation-logic-in-cta-beta-triggers/83151>\
**Category:** HubSpot Ideas\
**Tags:** forms, content\
**Created:** [June 12, 2023, 1:24pm UTC](https://community.hubspot.com/t/support-single-page-application-navigation-logic-in-cta-beta-triggers/83151 "2023-06-12T13:24:03Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![aarondicks](https://avatars.discourse-cdn.com/v4/letter/a/ecd19e/32.png) [@aarondicks](https://community.hubspot.com/u/aarondicks)\
**Post date:** [June 12, 2023, 1:24pm UTC](https://community.hubspot.com/t/support-single-page-application-navigation-logic-in-cta-beta-triggers/83151/1 "2023-06-12T13:24:03Z")

</div>

Currently CTA (Beta) logic does not work on Single Page Applications.

For SPAs with page tracking enabled in the HubSpot JS, please add support for the CTA logic listeners to trigger when the target pageview means there should be a CTA visible.

---

<div class="post-metadata">

**Author:** ![DSalazar63](https://avatars.discourse-cdn.com/v4/letter/d/a88e4f/32.png) [@DSalazar63](https://community.hubspot.com/u/DSalazar63)\
**Post date:** [June 13, 2023, 11:07pm UTC](https://community.hubspot.com/t/support-single-page-application-navigation-logic-in-cta-beta-triggers/83151/2 "2023-06-13T23:07:32Z")

</div>

This is so needed!

---

<div class="post-metadata">

**Author:** ![baribeau](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/baribeau/32/7115_2.png) [@baribeau](https://community.hubspot.com/u/baribeau)\
**Post date:** [November 15, 2023, 5:30pm UTC](https://community.hubspot.com/t/support-single-page-application-navigation-logic-in-cta-beta-triggers/83151/3 "2023-11-15T17:30:15Z")

</div>

Links to similar/identical issues, with slightly different descriptions or angles of approach:

- [https://community.hubspot.com/t5/APIs-Integrations/Force-CTA-Scripts-to-Run-on-History-Change-for-si…](https://community.hubspot.com/t5/APIs-Integrations/Force-CTA-Scripts-to-Run-on-History-Change-for-single-page/td-p/879567)
- [https://community.hubspot.com/t5/APIs-Integrations/When-we-change-the-route-in-our-React-single-page…](https://community.hubspot.com/t5/APIs-Integrations/When-we-change-the-route-in-our-React-single-page-application/m-p/785956#M63417)
- [https://community.hubspot.com/t5/APIs-Integrations/Tracking-code-problem-in-Angular-Site/m-p/360261](https://community.hubspot.com/t5/APIs-Integrations/Tracking-code-problem-in-Angular-Site/m-p/360261)
- [https://community.hubspot.com/t5/APIs-Integrations/pop-up-form-not-triggering-in-single-page-application/m-p/756377#M61471](https://community.hubspot.com/t5/APIs-Integrations/pop-up-form-not-triggering-in-single-page-application/m-p/756377#M61471)

---

<div class="post-metadata">

**Author:** ![TPijsel](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/tpijsel/32/201843_2.png) [@TPijsel](https://community.hubspot.com/u/TPijsel)\
**Post date:** [March 1, 2024, 3:54pm UTC](https://community.hubspot.com/t/support-single-page-application-navigation-logic-in-cta-beta-triggers/83151/4 "2024-03-01T15:54:39Z")

</div>

Hi, I am looking into the same. Any update or workaround for this one?

---

<div class="post-metadata">

**Author:** ![baribeau](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/baribeau/32/7115_2.png) [@baribeau](https://community.hubspot.com/u/baribeau)\
**Post date:** [May 23, 2024, 7:22pm UTC](https://community.hubspot.com/t/support-single-page-application-navigation-logic-in-cta-beta-triggers/83151/5 "2024-05-23T19:22:13Z")

</div>

I’ve outlined a slightly-hacky solution for this problem using Google Tag Manager and Javascript, at [https://community.hubspot.com/t5/APIs-Integrations/Force-CTA-Scripts-to-Run-on-History-Change-for-single-page/m-p/977800/highlight/true#M73696](https://community.hubspot.com/t5/APIs-Integrations/Force-CTA-Scripts-to-Run-on-History-Change-for-single-page/m-p/977800/highlight/true#M73696)

---

<div class="post-metadata">

**Author:** ![radapop](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/radapop/32/42241_2.png) [@radapop](https://community.hubspot.com/u/radapop)\
**Post date:** [July 22, 2024, 11:07am UTC](https://community.hubspot.com/t/support-single-page-application-navigation-logic-in-cta-beta-triggers/83151/6 "2024-07-22T11:07:51Z")

</div>

Hi everyone! Thanks for submitting feedback around this idea.

We recently launched a CTA API, through which CTAs are supported in Single Page Applications (SPAs). This API only works with CTAs created with [the new editor](https://knowledge.hubspot.com/ctas/create-calls-to-action), and does not support [Legacy CTAs](https://knowledge.hubspot.com/ctas/create-calls-to-action-ctas).

You can read more about this API here: [Accounts Dashboard | HubSpot](https://developers.hubspot.com/beta-docs/reference/api/marketing/calls-to-action-sdk)

---

<div class="post-metadata">

**Author:** ![ScottMoyse](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/scottmoyse/32/63419_2.png) [@ScottMoyse](https://community.hubspot.com/u/ScottMoyse)\
**Post date:** [November 4, 2024, 8:39am UTC](https://community.hubspot.com/t/support-single-page-application-navigation-logic-in-cta-beta-triggers/83151/7 "2024-11-04T08:39:38Z")

</div>

@radapop I’m extremely glad there’s now proper API support for this. We are wanting to use CTA’s to provide in app help for new users. Not an ideal solution for in app help, but it’s a good start for us at the moment.
