Relieve the pressure... Put shoes on... ride.
This happened to me at work one day when a steel foot pedal landed on my big toe. I was in pain for 2 days before I relieved the pressure. The whole toenail fell off and its not quite right almost 3 years later. But anyway, I had to wear closed toe shoes at work so that made my decision for me.
Hope it feels better soon!