🧩 Laravel Integration Guide

You can integrate Trakg into your Laravel app effortlessly by adding a single script tag.

βœ… Basic Setup (Blade Template)

Insert the following script in your main Blade layout, typically found at:
// resources/views/layouts/app.blade.php or similar
Place it right before the closing </body> tag:
<!-- Trakg Tracking Script -->
<script defer src="https://cdn.trakg.com/api/v1/tracker.min.js?id=YOUR_ID_GIVEN"></script>
πŸ” Replace YOUR_ID_GIVEN with your actual Site ID from the Trakg dashboard.

βš™οΈ Best Practices

  • βœ… Always use defer to prevent blocking page rendering.
  • βœ… Keep the script at the end of <body> for better performance.
  • βœ… No need to change your form markup β€” Trakg works with native form, input, textarea, and select elements.
  • βœ… It supports Blade forms, Livewire forms, and even Alpine.js interactivity.

πŸš€ You’re Ready!

Once installed, visit your Trakg dashboard to:
  • View partial and completed leads.
  • Monitor real-time form activity.
  • Export lead data.
  • Analyze form abandonment trends.
Need help? Contact Support or view app.trakg.com.