The Gulf of Tonkin incident was significant because it led to the Gulf of Tonkin Resolution, a law passed by Congress which authorized the president to use military force to defend South Vietnam from North Vietnam. As the author above explains, there were actually two incidents in the Gulf of Tonkin in August 1964, one on August 2nd in which the North Vietnamese attacked a U.S. destroyer in international waters, and another on August 4th when a U.S. vessel thought it was under attack but probably actually wasn't. The subsequent horror of the Vietnam War, and the fact the August 4th attack probably didn't happen, has given the Gulf of Tonkin incident a notoriety that it doesn't entirely deserve.
The fact is that the Vietnam War would have happened without the Gulf of Tonkin incident or the resolution; the incident merely provided a good rallying cry, and the resolution useful political cover. That it wasn't legally necessary is clear from the fact that it was repealed in January 1971, and yet the war still continued - and that Congress felt the need to pass the War Powers Resolution in 1973 to attempt to alter the balance of warmaking power between the legislative and the executive.
To understand all this, you have to look at the incident in context. By August 1964, North Vietnam was nearly five years into a campaign of aiding Communist insurgents in South Vietnam to attempt to overthrow the South Vietnamese government, and violating the neutrality of its neighbours to smuggle men and equipment south in the process. By mid-1965, they would be well on their way to succeeding, which is what actually caused President Johnson to dispatch American combat forces there. The U.S., for its part, was nearly five years into a clandestine operation - much, much smaller and less successful than the North Vietnamese one - to infiltrate and harass North Vietnam.
In their efforts to infiltrate North Vietnam, the Americans and their South Vietnamese allies had no grandiose goals. Having already rejected the idea of trying to actually overthrow the North Vietnamese regime - the Chinese would never have allowed it and might have started World War III in response, or so the U.S. thought - they were simply trying to distract them from their efforts south of the border, and maybe cause some minor disruption. Early attempts to parachute men in to conduct sabotage operations had been a dismal failure, and the Americans had plumped for training South Vietnamese commandos to attack various coastal installations on speedboats. They often didn't come back alive. The USS Maddox, the boat attacked by the North Vietnamese, was gathering intelligence in support of these efforts, albeit in international waters.
The North Vietnamese, meanwhile, had spent years infiltrating men and munitions into South Vietnam to take aim - quite literally - at American forces there, who at this time were just deployed in an "advisory" role, helping the South Vietnamese. The Gulf of Tonkin incident was only one in a series of notable attacks on American forces in the region around this time. In November 1964, the Viet Cong mortared the Bien Hoa Air Base, damaging or destroying dozens of aircraft and killing or wounding about as many men. In February 1965, the Viet Cong attacked Camp Holloway, a helicopter base at Pleiku in the mountains, with similar results. After this latter attack, when the administration was discussing whether to respond with a large-scale escalation in its military efforts, President Johnson's National Security Advisor McGeorge Bundy chimed in: "Pleikus are like streetcars".
And this was the salient point. These provocations were like streetcars - if you don't take this one, another one will come along soon enough. And so it was with the Gulf of Tonkin incident. An attack on a U.S. ship in international waters was undoubtedly fairly stupid on the part of North Vietnam, but it fit a general pattern of aggression on the part of the North against South Vietnam and those who had crossed the sea to protect it. There was an awful lot of noise and worry about the detailed chain of events - for instance, the U.S. had bombed North Vietnam after the Gulf of Tonkin incident, which some people thought had then provoked the Bien Hoa and Pleiku attacks - but this was almost irrelevant; if the Gulf of Tonkin incident hadn't happened, then something very similar would have. It was inherent in the fact North Vietnam was determined to take over the South, and the U.S. was determined to stop them.
Finally, as I noted, the irrelevance of the resolution is proven by the fact it was repealed in 1971, and yet the war continued. American participation in the Vietnam War was winding down in 1971, for sure, but it was still very much active - and in 1972 a massive air and sea operation would crush an invading North Vietnamese army, buying South Vietnam three more years of survival. After the resolution was repealed, the Nixon administration resorted to the hoary old trick of most post-WW2 American administrations - it argued that it didn't need congressional approval to wage war, because the president could do it anyway. Or, as Tricky Dick said elsewhere, "if the president does it, that means it's not illegal". Congress would later pass the War Powers Resolution to try, without much success, to make it otherwise so.
Still, even if it had been legally irrelevant, it had been politically very salient - the resolution allowed President Johnson, when he sent the first combat troops in 1965, to do so under what looked like the cover of a bipartisan consensus, a nation of two parties at peace with each other on issues of national security and presenting a united front to the world, especially when it came to dealing with pesky Commies. Only two senators voted against the resolution. Very little of that comity would remain when the chain of events of which the Gulf of Tonkin incident was a part was finally done.