It very well could be your throttle position sensor, or a vacuum leak or plug, fault in the fuel or electrical systems, leaking EGR valve, plugged PCV valve, leaking head gasket, or camshaft lobes worn.
Your throttle position sensor should be right underneath your throttle body where the air intake tubes go into it. Does your chack engine light flash on or stay on at all? Also what kinda car are we talking about here?