It can take a few months to know how to play chords in songs. You need to get used to the chord shapes and learn the rhythmic play of the right hand. During this time, you will be able to master basic music theory.
However, if you want to know how to play blues, rock, country, or any other style of popular music, be prepared for a much longer time. In addition to guitar chords and strumming techniques, you will learn riffs, scales, and progression typical for the style. Let’s be optimistic to say you can play at an “audible level” in 6 months.
However, when we talk about jazz or classical guitar, you will need even more toughness and time. It includes more advanced knowledge of theory, superstructure chords, progressions, chord substitutions, in the case of classical music, reading notes, and playing with your right fingers.
As I said, the particular time frames are only a very rough estimate. The real time of progress will depend on your approach and the following criteria: