I use
Open Broadcaster Software (OBS for short), which is free and can both record and stream, even simultaneously.
You can have multiple input sources such as multiple monitors, webcam, text/graphics overlay etc.
For live streaming I usually go with around 1800-2000kbps for 30fps video with x264 codec and 128kbps stereo audio with AAC codec.
I have very bad experience with the NVENC (nVidia encoder) codec because as soon as there's any motion, the image just breaks apart and lose all detail, as if it's very bad bitrate even though it's clearly not.
As for recording, I tend to use about 8000kbps if I record at 60fps and 4500kbps for 30fps. That's usually enough.