Transmission problem on 1999 Toyota 4Runner

Occasionally when I start out the transmission won't "shift" but it corrects itself fairly soon. There can even be a couple months in between "episodes."

Asked by for the 1999 Toyota 4Runner
I would suggest driving the Toyota getting the oil hot, draining the transmission, removing the transmission oil pan to drain more fluid and be able to inspect the oil in the oil pan for debris. Change the transmission filter reseal the oil pan refill with transmission oil and a transmission additive made by a company called Lubegaurd drive the Toyota through all the gears and recheck/top up the transmission oil level as required.
I received more information that you had been at a traffic light and pressed the accelerator pedal down and the truck didn't accelerate. Did the engine race up/raise revs per minute? If so the problem can be the transmission. If the RPM did not raise as you press down on the accelerator it could be many things, A scan tool should be used to see if there are any codes or pending codes stored in the truck's computer. It would be interesting to watch live data stream information on the scan tool to see throttle position values and air flow readings to see how much air the computer thinks is entering the engine on acceleration to see if any thing is odd. Fuel trim figures can be read right of the scan tool as well.