Trefil is a small village in the county borough of Blaenau Gwent, south Wales. It lies at the top of the Sirhowy Valley, three miles northwest of Tredegar. The boundary of the Brecon Beacons National Park lies one mile to the north of the village.
The village is sited in the bottom of a broad valley which cuts through the moorlands between the Heads of the Valleys Road and the Dyffryn Crawnon valley to the north. At 409 meters above sea level, the Ordnance Survey recognise Trefil as the highest village in Wales. Trefil is served by a single cul-de-sac road which leaves the A465 Heads of the Valleys Road 1.5 miles to the south.
Trefil is perhaps best known for its limestone quarries - a major one immediately north of the village is operational whilst Cwar yr Ystrad, Cwar yr Hendre and Cwar Blaen-dyffryn to the west and northwest are no longer operational. The Trefil Tramroad and the Sirhowy Tramroad formerly linked the quarries with the heavily industrialised areas to the south, providing limestone for the furnaces. The former Brinore Tramroad connected the quarries at Trefil with the Monmouthshire and Brecon Canal at Talybont in the Usk Valley to the north.
Open moorland rises to east and west of the village, the slopes to the west being known as Trefil Ddu and those to the east as Trefil Las. The moorland of Mynydd Llangynidr to the east undulates considerably and contains a number of caves beneath its surface. Most famous amongst these is Chartist's Cave one mile to the northeast of the village
The village name may derive from the terms 'tref' and 'mil' signifying the 'farm of the lesser celandine', a plant which might be expected to grow in the stream which flows through the place, the Nant Trefil.
Trefil Quarries and Trefil Ddu are noted birding sites; this area is the last remaining site in Gwent where ring ouzel occurs regularly, and other species present include raven, wheatear, stonechat, whinchat, snipe and red grouse.