FsCheck
FsCheck is a free library for automatically checking properties of .NET programs against randomly generated inputs.
What FsCheck is
FsCheck is a free library for automatically checking properties of .NET programs against randomly generated inputs. Developers can express properties in F#, C#, or VB and run them with the built-in runner from an interactive session, command-line program, or test framework. The project documents integrations with xUnit.net and NUnit, along with user-created integrations for Expecto, Fuchu, AutoFixture, and MSTest. When a property fails, FsCheck shrinks the input and presents a minimal counterexample. Users can define their own generators and shrinkers and bundle them as Arbitrary instances. Its NuGet packages include NUnit and xUnit.NET plugins. The project’s BSD license permits modification and redistribution for commercial and non-commercial use. Documentation covers version 2.x and is described as outdated and incomplete, while version 3.x is maintained and receives fixes and features. The stateful model-based testing API is experimental and not covered by semantic-versioning guarantees. Properties cannot use generic types, and the documented exception-expectation function is unavailable in the C# API. FsCheck supports Linux, macOS, and Windows.
Good
- Writes properties in F#, C#, or VB.
- Shrinks failing inputs to minimal counterexamples.
- Allows custom generators and shrinkers.
- BSD license permits commercial and non-commercial redistribution.
Watch out
- Documentation covers outdated and incomplete version 2.x.
- Stateful model-based testing is experimental.
- Properties cannot have generic types.
- C# API lacks the documented exception-expectation function.
Who it suits
FsCheck suits developers who want generated-input property checks for .NET programs. It is relevant if your workflow uses F#, C#, or VB and a supported runner or test framework.
Verdict
FsCheck offers property-based testing with customizable generated inputs and integrations for common test frameworks. Check the documentation version and experimental API caveats before relying on those parts of the project.
Plans and prices
From FsCheck's own pricing page, checked 7 Oct 2026.
| Plan | Price | What it gives you |
|---|---|---|
| FsCheck | Free | BSD-licensed library · NuGet packages |
The facts
Each one read from FsCheck's own pages, with the date it was checked.
What it does
- Audience
- FsCheck is for developers who want to test properties of .NET programs with generated inputs.checked 7 Oct 2026
- C# limitation
- The documented function for expecting exceptions is not available in the C# API.checked 7 Oct 2026
- Counterexamples
- When a property fails, FsCheck displays a minimal counterexample.checked 7 Oct 2026
- Current documentation
- The project says its 2.x documentation is out of date and incomplete, while version 3.x is maintained and receives new features and fixes.checked 7 Oct 2026
- Documentation status
- The site warns that its documentation covers version 2.x while version 3.x is maintained and receives new features and fixes.checked 7 Oct 2026
- Experimental feature
- The experimental model-based testing API is exempt from semantic versioning guarantees, so minor releases may break code using it.checked 7 Oct 2026
- Failure reports
- When a property fails, FsCheck displays a minimal counterexample by shrinking the failing input.checked 7 Oct 2026
- Generators
- Users can define custom test data generators and shrinkers, and package them together in Arbitrary instances.checked 7 Oct 2026
- Installation
- FsCheck and its NUnit and xUnit.NET plugins can be installed from NuGet.checked 7 Oct 2026
- Integrations
- The project documents integrations with xUnit.net and NUnit, and user-created integrations with Expecto, Fuchu, AutoFixture and MSTest.checked 7 Oct 2026
- Languages
- Properties can be expressed in F#, C# or VB.checked 7 Oct 2026
- License
- The project says its BSD license permits modification and redistribution for commercial and non-commercial purposes.checked 7 Oct 2026
- Property limitation
- Properties cannot have generic types; the documentation says type annotations can be used to resolve types.checked 7 Oct 2026
- Purpose
- FsCheck automatically tests .NET programs by checking properties against randomly generated cases.checked 7 Oct 2026
- Stateful testing
- Model-based testing for stateful systems and objects is in the Experimental namespace, where semantic-versioning promises do not apply.checked 7 Oct 2026
- Support
- The project invites users to report issues on GitHub and says contributors may open issues about documentation problems or gaps.checked 7 Oct 2026
- Testing modes
- FsCheck includes a built-in test runner and can run properties from F# or C# interactive, command-line programs or test frameworks.checked 7 Oct 2026
- Test runner
- FsCheck includes a built-in runner usable from F# or C# Interactive, command-line programs, or a test framework.checked 7 Oct 2026
The full review of FsCheck
FsCheck is a free property-testing library for .NET, best suited to developers who want to probe program behavior with generated inputs. Its failure shrinking and flexible generators make it a strong fit for properties that are hard to cover with hand-picked examples, provided teams are comfortable with its API constraints and documentation caveats.
Overview
FsCheck checks developer-defined properties against randomly generated cases, helping uncover edge cases that a short list of examples may miss. The approach works best when a team can state a useful rule about its code; it does not supply those rules or replace ordinary example-based tests.
When a check fails, FsCheck shrinks the input and reports a minimal counterexample. That gives developers a more focused failure to investigate. Custom generators and shrinkers can be grouped into Arbitrary instances, allowing teams to shape both the test data and how failures are reduced.
Properties can be written in F#, C# or VB. The project documents integrations with xUnit.net and NUnit, plus user-created integrations for Expecto, Fuchu, AutoFixture and MSTest. Its built-in runner can execute properties from F# or C# Interactive, command-line programs, or a test framework. Parameterized cases and parallel execution are supported.
Key features
- Generated property checks: Random inputs exercise a stated property across many cases, which suits rules expected to hold broadly. Properties cannot have generic types; type annotations can resolve types when needed.
- Failure shrinking: FsCheck reduces a failing input to a minimal counterexample, making an unexpected case easier to inspect and reproduce.
- Custom generators and shrinkers: Arbitrary instances bundle custom data generation with custom shrinking. This is useful when the default shape of generated inputs does not match the domain being tested.
- Runner and framework support: The built-in runner offers a way to run checks from interactive sessions, command-line programs, or test frameworks. The documented exception-expectation function is unavailable in the C# API, a relevant gap for C# teams that need that behavior.
Pricing
FsCheck costs nothing. The plan is a BSD-licensed library distributed through NuGet; the project says the license permits modification and redistribution for commercial and non-commercial use. There is no paid tier or free trial to weigh against a capped entry plan.
FsCheck and its NUnit and xUnit.NET plugins can be installed from NuGet. Developers can use the same free library across F#, C# and VB, with no per-seat or usage charge stated.
Platforms
FsCheck supports Linux, macOS and Windows. Its language support covers F#, C# and VB, making it relevant to .NET teams working across those operating systems.
Who it's for
FsCheck is a good choice for .NET developers who can express expected behavior as properties and want generated cases to challenge those rules. Teams that need control over domain-specific inputs can benefit from custom generators and shrinkers, while shrinking can reduce the work of understanding a discovered failure.
Teams adopting it should account for the documentation gap: the site says its 2.x documentation is out of date and incomplete, while version 3.x is maintained and receives new features and fixes. Developers should check which version their project uses. Stateful model-based testing is available in an Experimental namespace, where minor releases may break code because semantic-versioning guarantees do not apply; it is a less suitable foundation for code that needs a stable API.
Pros and cons
- Pros: Minimal counterexamples make generated failures easier to diagnose; custom generators and shrinkers let teams tailor inputs; the built-in runner and documented framework integrations offer several ways to run properties; the BSD license permits commercial use and redistribution.
- Cons: The current documentation is described as out of date and incomplete for 2.x, so version-specific guidance needs care; properties cannot use generic types; the documented exception-expectation function is missing from the C# API; experimental stateful testing carries API breakage risk between minor releases.
Alternatives
Property-Based Testing Tools is a useful category overview for comparing options. For a .NET project, FsCheck is the option here with F#, C# and VB properties and a NuGet distribution.
Choose ScalaCheck if a free BSD-3-Clause library better fits your project. Choose Racket QuickCheck when you want a free Racket package and can use Racket v6.0 or newer. Gopter is a free, MIT-licensed Go property-testing library. Choose fast-check for a free, MIT-licensed JavaScript or TypeScript option. JSVerify is another free, open-source JavaScript property-testing library. Choose Scala Hedgehog for an open-source Scala testing library, or PropCheck for a free MIT-licensed Ruby gem requiring Ruby 2.5.1 or newer. QCheck is a free OCaml property-testing library under the BSD-2-Clause license.
Unit Testing Frameworks provides a broader category view for readers comparing testing approaches.
Verdict
Choose FsCheck if you build .NET software and want generated inputs, customizable data and shrunk counterexamples in a free property-testing workflow. Its main advantage is turning a failing property into a small, inspectable case. Look elsewhere if the C# exception API gap, generic-property constraint, or experimental model-based API conflicts with your needs; check the version 3.x documentation carefully before settling on an integration.
Getting started
- Open the FsCheck website for project information.
- Install FsCheck or its NUnit or xUnit.NET plugin from NuGet.
- Write properties in F#, C# or VB.
- Run properties with the built-in runner from an interactive session, command-line program or test framework.
Limits worth knowing
FsCheck is free, but properties cannot have generic types, and the documented exception-expectation function is unavailable in the C# API. Experimental model-based testing does not have semantic-versioning guarantees; the project documentation describes version 2.x and is outdated and incomplete.
Questions
How much does FsCheck cost?
The listed plan is free, and FsCheck is BSD-licensed.
Which languages can I use?
Properties can be expressed in F#, C# or VB.
Which platforms are supported?
The listed platforms are Linux, macOS and Windows.
Which test integrations are documented?
The project documents xUnit.net and NUnit integrations, plus user-created integrations for Expecto, Fuchu, AutoFixture and MSTest.
Is FsCheck open source?
The project describes its license as BSD, permitting modification and redistribution for commercial and non-commercial purposes.
What are the key limitations?
Properties cannot have generic types, and the documented exception-expectation function is not available in the C# API. The stateful model-based API is experimental and is not covered by semantic-versioning guarantees.
Alternatives to FsCheck
- 1

fast-check
Free planOpen sourceWebAPILinuxSelf-hosted7.1Free plan - 2
ScalaCheck
Free planLinuxmacOSWindows6.6Free plan - 3
Gopter
Free planLinuxSelf-hosted6.4Free plan - 4
JSVerify
Free planWebSelf-hosted6.4Free plan - 5
Racket QuickCheck
Free planLinuxmacOSWindows6.4Free plan - 6
QCheck
Free planLinux6.0Free plan
