Many of the 200 or so routes run 24 hours. You can pay on the bus, but must have correct change in coins. (Long distance cummuter buses are located at Port Authority Bus Terminal (40th st West / 8th Ave)
New York's Subway Metro is the best way to get around. It is made up of around 470 stations. It operates 24 hours, although there is a reduced service at night. You must buy ticket before attempting to go through the turnstiles.
Taxis (Cabs) can by hailed from the street. There are also designated taxi stands at stations. Price is around $2.50 to start then $.40 per per 4 blocks. ($1 surcharge 4pm to 8pm Mon - Fri / $0.50 night surcharge 8pm to 6am)
The train system is handy for getting to suburbs and neighbouring towns. There are two major stations - Grand Central Terminal (42nd st/Park Ave) and Pennsylvania (Penn) Station (32nd st/7th Ave), the latter is also used for long distance service and for travel to Canada.
The same ticket (Metrocard) is valid on both buses and the subway. A single ticket costs around $2 , but you can make savings by buying a $7 metrocard, giving you four rides - a saving of $1. (Express bus ride is $5)
Also available are Unlimited Ride MetroCards: 1-Day Fun Pass ($7.50), a 7-Day ($25), 14-Day ($47), 30-Day ($81) . (Note, you still have to pay extra when using Express buses!)
Metropolitan Transportation Authority
New York City Taxi Commission