# Pinning MSRV in a Rust workspace

> Setting rust-version in Cargo.toml makes cargo fail early on older toolchains.

Date: 2026-09-02  
Author: Nik  
Tags: rust  
Source: https://devscratch.com/en/posts/rust-msrv

Setting `rust-version` in `Cargo.toml` makes cargo fail early on older toolchains instead of producing confusing errors deep in a dependency.

```toml
[package]
rust-version = "1.85"
```
