Millisecond pulsars, old neutron stars spun-up by accreting matter from a companion star, can reach high rotation rates of hundreds of revolutions per second. Until now, all such "recycled" rotation-powered pulsars have been detected by their spin-modulated radio emission. In a computing-intensive blind search of gamma-ray data from the Fermi Large Area Telescope (with partial constraints from optical data), we detected a 2.5-millisecond pulsar, PSR J1311−3430. This unambiguously explains a formerly unidentified gamma-ray source that had been a decadelong enigma, confirming previous conjectures. The pulsar is in a circular orbit with an orbital period of only 93 minutes, the shortest of any spin-powered pulsar binary ever found.Almost exactly 30 years ago, radio observations detected the first neutron star with a millisecond spin period (1). Launched in 2008, the Large Area Telescope (LAT) on the Fermi Gamma-ray Space Telescope (2) confirmed that many radio-detected millisecond pulsars (MSPs) are also bright gamma-ray emitters (3). In each case, gamma-ray (0.1 to 100 GeV) pulsations were revealed by using rotation parameters obtained from radio telescopes (4) to assign rotational phases to LATdetected photons.The Fermi LAT also provides sufficient sensitivity to detect pulsars via direct searches for periodicity in the sparse gamma-ray photons. Such blind searches (5) of LAT data for solitary pulsars have so far unveiled 36 younger gamma-ray pulsars (6-9) with rotation rates between 2 and 20 Hz. In the radio band, all but four of these objects remain completely undetected despite deep follow-up radio searches (10). This is a large fraction of all young gamma-ray emitting neutron stars and shows that such blind-search gamma-ray detections are essential for understanding the pulsar population (11). However, no MSP has been detected via gamma-ray pulsations until now, and so we have not been able to see whether a similar population of radio-quiet MSPs exists.The blind-search problem for gamma-ray pulsars is computationally demanding, because the relevant pulsar parameters are unknown a priori and must be explicitly searched. For observation times spanning several years, this requires a dense grid to cover the multidimensional parameter space, with a tremendous number of points to be individually tested. Blind searches for MSPs in gamma-ray data are vastly more difficult than for slower pulsars largely because the search must extend to much higher spin frequencies [to and beyond 716 Hz (12)]. Furthermore, most MSPs are in binary systems, where the additionally unknown orbital parameters can increase the computational complexity by orders of magnitude. Thus, blind searches for binary MSPs were hitherto virtually unfeasible.We have now broken this impasse, detecting a binary MSP, denoted PSR J1311−3430, in a direct blind search of the formerly unidentified gamma-ray source 2FGL J1311.7−3429, one of the brightest listed in the Fermi-LAT Second Source Catalog [2FGL (13)]. This source also had counterparts in several ea...