Skip to main content

Is it possible to capture the screen resolution that users’ have when using our app?

We’re looking to optimize UI and are finding that the resolution we’re optimizing for may not be the one that most users use.

Hi Adam, thanks for posting to PX Community!

 

I do think this is possible and here is one way to do this…

  • add a new custom User Attribute in PX (e.g. “Screen Resolution”)
  • ask your development team do the following:
    • add the necessary JavaScript in your web application to collect the screen “width” and “height” for each user.  Sample code can be found here
    • add a new custom User attribute/value pair to your existing PX Identify call JavaScript code. Sample PX Identify JavaScript code is below, but I have not tested this myself:
    •  

After this is implemented by your development team, then you will see this data as a Custom Attribute on the Full User Profile and also be able to use it for filtering in Analytics.

 

I hope this helps!

 

 


Awesome, thanks James :thumbsup_tone3:


Since you’re already gathering data like OS and browser type, isn’t screen size something that you could just pull down automatically and make it a part of native data set?


Is there a way to piggy back off this and also track the scaling % ?

 

 


Reply