To switch from your shader based rendering back to the fixed pipeline:
glUseProgram(0);
To switch from your FBO rendering back to rendering to the default framebuffer:
glBindFramebuffer(GL_FRAMEBUFFER, 0);
You can use vertex arrays in the fixed pipeline. But if you want to unbind your vertex arrays/buffers, it's the same thing. Just bind 0 to release your bindings, e.g.:
glBindVertexArray(0);
glBindBuffer(GL_ARRAY_BUFFER, 0);
Edit: Answer to follow-up question about the overhead.
The simple answer is... it depends. Overhead for certain operations can be very different depending on platform/hardware. As far as it can be answered in relatively general terms:
- I'm not aware of any hardware made even moderately recently that still has the full fixed pipeline. Everything made within the last 5-10 years always runs shaders. If you use the legacy fixed pipeline, the driver generates shaders for you. That shader generation could take a bit of time when you switch to the fixed pipeline, but tends to be heavily optimized (as long as people still run old benchmarks), and most likely uses cached shaders. So it shouldn't be very significant.
- Compiling shaders is expensive. Simply switching shaders is low overhead. I benchmarked it at sub-microsecond times on platforms I worked on, comparable to binding vertex buffers. Could be higher on other platforms, I guess, but e.g. modern games use lots of different shaders, and being able to bind them with low overhead is critical.
- Binding/unbinding vertex buffers is low overhead. And very heavily optimized in drivers since it has big influence on many commonly used benchmarks, particularly ones that don't generate enough shader load to keep the GPU fully busy
- The overhead for binding a different draw target (e.g. switching from FBO to default framebuffer) is highly platform dependent. But it's at least moderately expensive on most platforms, and supposedly a pretty bad performance killer on some platforms that shall rename nameless. No reason to worry if you don't switch too frequently, but you definitely don't want to do this more often than needed.