Get FREE email communications from Fodor's Travel, covering must-see travel destinations, expert
trip planning advice, and travel inspiration to fuel your passion.
It depends on what you want to see and experience and your preferred pace, but in general, I'd recommend that you plan on spending at least 5 days there.
Have been twice - once for 3 days and one for 5 - and still have things I want to see/do. You should list what your must sees are - and work from there.
PamL1, as kja and nytraveler have said you really need to deceide what you'd like to see. I have been to St Petersburg once, I was there for five days, and I felt that was adequate; three days would have been too short.