Scroll marker target pseudo-classes
Limited availability
The :target-current CSS pseudo-class selects the active scroll marker (as in ::scroll-marker), while the :target-after and :target-before pseudo-classes select the inactive markers preceding and following the active scroll marker.
Browser support
- Chrome 142 Released on 2025-10-28
- Chrome Android 142 Released on 2025-10-28
- Edge 142 Released on 2025-10-31
- Firefox Not supported
- Firefox for Android Not supported
- Safari Not supported
- Safari on iOS Not supported
Need this feature?
Leave a 👍 on the feedback issue
Don't forget to also leave a comment explaining your specific use case.
MDN documentation
Specifications
Web Platform Tests (WPT)
View the latest WPT test results for this featureView as JSON | Edit this feature | Report an issue | Web-features entry: source, dist