# Route Values and the Query String

Values reach an action from the route (/products/7) or the query string (?page=2). Choose which with the address's meaning, give optional values defaults, and use \[FromRoute\] and \[FromQuery\] to be explicit.

![Cheat sheet: Route Values and the Query String](https://fsdtrainingmedia.blob.core.windows.net/public/images/2026/11/feba65f253d642099233b4449fd661a2.webp)

- Category: ASP.NET Core
- Level: Journeyman
- Tags: \[FromQuery\], \[FromRoute\], aspnet-core, c-sharp, Query String, Route Parameter (aspnet-core)
- Updated: November 3, 2026

Source: https://www.ask-codey.com/cheat-sheets/routing-in-aspnet-core-route-values-and-the-query-string-cheat-sheet
