The x-ray-absorption near-edge structure (XANES) of sulfur hexafluoride, SF6, in the gas phase has been measured with high energy resolution at the sulfur L2,3 and fluorine K ionization thresholds using synchrotron radiation from the SX700/II monochromator at BESSY. Besides dominant transitions to core-excited inner-well states, several series of Rydberg states with vibrational fine structure were resolved below the sulfur L 2,3 thresholds. Using the Rydberg formula, quantum defects of delta(s) = 1.80 and delta(d) = -0.03 were obtained for the s and d Rydberg orbitals of the central sulfur atom. A Franck-Condon analysis was used to determine the vibrational spacing and the S-F bond length of the (S 2p3/2)(-1)4s1 core-excited state. The presence of vibronically coupled transitions below the sulfur L2,3 edges was confirmed. The derived natural linewidths of the (S 2P1/2,3/2)-1 Rydberg states were found to be strikingly narrower than those of the (S 2p1/2,3/2)-1 inner-well resonances. Line-shape analysis also revealed significant inhomogeneous broadening of the (S 2p1/2,3/2)-1a1g1 states, which is attributed to unresolved vibrational structure. Large Lorentzian contributions to the line shapes of the (S 2P1/2,3/2)-1t2g1, resonances suggest that vibrational effects are relatively small for those states.