Best way to redirect users to desktop version or mobile version website based on their device on my PHP coded website?

This page summarizes the projects mentioned and recommended in the original post on /r/PHPhelp

Our great sponsors
  • SurveyJS - Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • WorkOS - The modern identity platform for B2B SaaS
  • Bootstrap

    The most popular HTML, CSS, and JavaScript framework for developing responsive, mobile first projects on the web.

  • Like others have said, responsive CSS is your friend. Using getbootstrap.com is a good option, or tailwindcss.com seem to be the new popular framework.

  • Mobile-Detect

    Mobile_Detect is a lightweight PHP class for detecting mobile devices (including tablets). It uses the User-Agent string combined with specific HTTP headers to detect the mobile environment.

  • If you really can’t make your website responsive, then there’s a great php library here http://mobiledetect.net

  • SurveyJS

    Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App. With SurveyJS form UI libraries, you can build and style forms in a fully-integrated drag & drop form builder, render them in your JS app, and store form submission data in any backend, inc. PHP, ASP.NET Core, and Node.js.

    SurveyJS logo
  • Tailwind CSS

    A utility-first CSS framework for rapid UI development.

  • Like others have said, responsive CSS is your friend. Using getbootstrap.com is a good option, or tailwindcss.com seem to be the new popular framework.

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts