Assuming you're from one of the 93 countries that are eligible for Visa exemptiom, you will be allowed a visa-free entry for 60 days (with a possibility to extend that with another 30 days at an Immigration office for 1900 thb). That means you wont have a visa - You get a stamp in your passport when you enter Thailand.
It is also possible to apply for a tourist visa from your homecountry before you travel... A tourist visa allow the same time of stay as the visa exemption (60+30 days). There are no tourist visa that give you 90 days from start... you will need to get an extension to get a total of 90 days.
If travelling without visa, you may (or may not) be asked to show an onward ticket out of Thailand within 60 days from your arrival (i.e. you should be able to show a ticket if asked by the airline and/or by the Immigration officer at the airport).
If you travel with a tourist visa, that you applied for in your homecountry before your trip, you need proof of onward travel within 90 days from your arrival date.
There are other visas as well, that might grant you more days, but you need to research that on your own. Check for information on the web for the Thai Embassy in your homecountry:
****************************