Tracking Pages Visited During Form Submission with AI Agent

  • Brian Posalski
    Asked on April 15, 2025 at 12:41 PM

    This may work if the form is embedded on a specific page or URL because the admin can match that url with source. But what about the scenario where an AI agent is helping to fill out a form. The Agent appears on the bottom right of every page on the website. How can the form extract the page (or pages) that the user has visited during the session so that we can understand what the user was looking at during the time of chat/form submission?

  • Kyle JotForm Support
    Replied on April 15, 2025 at 1:24 PM

    Hi Brian,

    Thanks for reaching out to Jotform Support. To address the scenario you mentioned, where an AI agent is assisting users and the form needs to capture the pages visited during their session, you can leverage session tracking and URL parameters.

    A possible solution would be to use custom JavaScript on your website to log the pages a user visits during their session. This log can then be passed as a hidden field in the form at the time of submission. For example, you could store the visited URLs in the browser's local storage or a session variable and then populate this data into a hidden field when the form is accessed.

    Unfortunately, this functionality requires custom code implementation outside Jotform's standard features. You may need to involve a developer to create a script for this tracking and integrate it with your form.

    Let us know if there’s anything else we can help you with. 

Your Answer