I tried to make an audio amp based on LM386 but the output is noisy when the audio is playing. Here is my circuit schematic I built on a solderless protoboard:
Power is supplied from four 1.5V batteries. I also added 50pF between input terminals to filter-out radio noise. When there is no sound playing, the amp is nice and quiet, but once the music starts the noise appears. There is also some reverberation when the music stops. When the inverting input is connected to the ground the effects get even worse. My guess is that there is a feedback loop between output and input, but I don't know why and how can be fixed. Adding coupling capacitor and/or voltage divider at non-inverting input or adding a bypass 10uF capacitor doesn't change anything.
According to the comments, I removed the 50pF capacitor between the inputs, connected the inverting input to the ground and added the voltage divider at the input. This made the sound much cleaner, but there was no gain. Output volume was not amplified regardless of the capacitor between pins 1 and 8. Adding DC coupling before the potential divider makes gain work again but also makes the output really noisy.