Travis crashed his car last summer. He was found naked inside and was suspected of being drunk.
Travis was sentenced to two years of probation, a $2,000 fine and a 180-day suspended jail sentence. He was ordered to spend at least 30 days at an alcohol treatment facility, complete 100 hours of community service, and use an ignition interlock device on any vehicle he drives while on probation.
If probation is not successfully completed, Travis faces the jail time.
Authorities have said a Trans Am registered to Travis veered off a road Aug. 7 near Tioga, a town about 60 miles north of Dallas where the entertainer lives. The car struck several barricades in a construction zone.
Prosecutors said Travis was found lying in the roadway naked and was belligerent at the scene and while being transported to a hospital. He had a blood alcohol level of 0.21. The legal limit for driving is 0.08.
Travis also had faced a charge of retaliation for allegedly threatening officers, but as part of the plea agreement he will no longer face that charge.
Grayson County District Attorney Joe Brown said Travis' punishment is appropriate and "considerably more than is typically received on a DWI case."
"First time DWI defendants are rarely forced into in-patient treatment," Brown said in a news release. "He will be unable to leave the facility for 30 days. His fine and community service requirements are more than double what is usually received, and his probation term is the maximum available, and longer than the usual 18 months. All of that is appropriate in light of his behavior with the officers."
On Thursday, the judge in the case agreed with a defense motion asking that the arrest video and transcript not be released to the public.
Travis' lawyers have previously said the singer has a great deal of respect for law enforcement and has stopped drinking alcohol.
The August accident was among a string of recent run-ins with the law for Travis.
Police in suburban Dallas cited Travis following an Aug. 23 incident in a church parking lot in which he allegedly intervened in an argument involving a woman he knows and her estranged husband. Nobody was hurt.
Travis also was arrested last February in Denton County, northwest of Dallas, for public intoxication after police spotted a vehicle parked in front of a church and found an open bottle of wine and Travis smelling of alcohol. That case is no longer on file with the county court and appears to have been dismissed.
The Associated Press contributed to this report.