A lot of the time its competition. This could be between countries or businesses. Country's will compete to have the best military that is possible. War, for example, is a huge driver of technological advancement. Businesses compete for the consumers dollar. If business A can make something better faster and cheaper than business B, then business A has a better chance of earning more profits from its production and sale.
Other reasons includes mans inherent need to learn, answer questions about the world, and solve their problems. Problem solving is a huge one. Examples could include designing new farm equipment or refridgeration systems so that more people can eat at a lower price.