Vihara (विहार) is the Sanskrit and Pali term for a Buddhist monastery. It originally meant "a secluded place in which to walk", and referred to "dwellings" or "refuges" used by wandering monks during the rainy season.
The northern Indian state of Bihar derives its name from the word "vihara", probably due to the abundance of Buddhist monasteries in that area. The word "vihara" also been borrowed in Malay where it is spelled "biara," and denotes a monastery or other non-Muslim places of worship. In Thailand and China (called jingshe; Chinese: 精舎), "vihara" has a narrower meaning, and designates a shrine hall. It is called a "Wihan" (วิหาร) in Thai, and a "Vihear" in Khmer. In Burmese, wihara (ဝိဟာရ, IPA: [wḭhəɹa̰]), means "monastery," but the native Burmese word kyaung (ကျောင်း, IPA: [tɕáʊɴ]) is preferred.
In the early decades of Buddhism the wandering monks of the Sangha, dedicated to asceticism and the monastic life, had no fixed abode. During the rainy season (cf. vassa) they stayed in temporary shelters. These dwellings were simple wooden constructions or thatched bamboo huts. However, as it was considered an act of merit not only to feed a monk but also to shelter him, sumptuous monasteries were created by rich lay devotees (Mitra 1971). They were located near settlements, close enough for begging alms from the population but with enough seclusion to not disturb meditation.