OBS Studio can start recording automatically when we hit the Start Streaming button. The option to switch this on is hiding under Settings – General – Output.
The destination and file format for the resulting video file can be set under Settings – Output.