Yes, Matomo (Piwik) will automatically detect the device type of your visitors. In case the device type could not be detected automatically, you can define pixel thresholds to indicate when we should assume a device is a mobile or tablet device. To not having to configure these tablet and mobile thresholds every time you configure a heatmap, you can change them globally under “Administration => General Settings”.

You can view the heatmap data for desktop, tablet, and mobile users separately and of course you can apply any Matomo segments to heatmaps and session recordings.

Previous FAQ: How do I track only a specific target group?