This varies country by country. Some require minimal information, and for some the application process is complex. For example, some countries require you to list all the countries you’ve visited in the past five years.
The purpose of your visit can also affect how long it takes to get a visa. A tourist visa may be simple to acquire, but a business trip may require more documentation.
Most visa waiver schemes, such as the US, Australian and (soon to be implemented) EU waivers, are an online process that can take as little as a couple of hours.
If you’re planning to travel to a country for the first time, it’s best to look into the visa application process as soon as possible.