Nancy, many ships get to San Juan late in the afternoon, I remember the last time we were there we arrived around 4pm. If you plan on visiting the fort (El Morro), make sure you head there FIRST as it closes at 5pm.
Then you can wander around old town, enjoying the cobbled narrow streets as you make your way back to the pier. Stop and have a look at the Governor's Mansion on your way down back to the ship. Shops are open late and there is also a flea market down by the cruisehip terminal that is open till late at night.