Linlithgow is only 11 miles/18 km from Edinburgh International Airport .
By far the easiest option is to take the newly opened tram from the Airport to Edinburgh Park Train Station (about 10 minutes) and then change there for a train to Linlithgow. This costs around £9 for an adult with an all inclusive ticket and the whole journey takes around 30 minutes (allow extra time late evening or early morning for reduced train services).
There are no direct public transport links to Linlithgow from Edinburgh airport, however a dedicated airport bus service, Airlink Express, service 100, runs from outside the terminal building to Edinburgh city center (Waverley Bridge) Adult fares are £3.50 for a single, £6 for an open return and the journey takes an average 25 mins, tickets can be purchased from the kiosk at the bus stop. Once in Edinburgh city centre, there are direct bus and train links to Linlithgow.
Although there is no direct bus from the terminal, the number 38 which operates between Edinburgh-Linlithgow-Falkirk-Stirling does stop near the airport. Passengers must walk from the terminal towards the Hilton hotel, then continue on out of the airport complex, past a secure car park service, continue under the motorway bridge and then up some stairs and on to the motorway bus stop. This walk takes about 10-15 minutes and is not suitable if you have a lot of luggage, are disabled or a large group of people. There is a chance a taxi may run you there in a few minutes. The service is fairly regular (timetable - add/subtract about 5 minutes to/from ratho station for airport times) and runs from early morning until late at night and fares are very reasonble. Journey time to Linlithgow is about 45 minutes, although if using the bus to get TO the airport allow a lot of time for delays, especially in the mornings and other buys periods. It may be worth getting the service before the one you think will allow you extra time just to be sure!
At night/early morning the service may start or terminate at Linlithgow Cross, but for most of the day it will run through the main street of the town and out towards Falkirk.
Another option is to take the local 35 Bus from The airport to Edinburgh Park train station and then take the train from there to Linlithgow. Almost every train bound for Glasgow, (And every train bound for Dunblane or Sitrling) which stops at Edinburgh Park station will also stop at Linlithgow. The journey from Edinburgh Park to Linlithgow is non stop and takes around around 15 minutes.
Linlithgow is conveniently placed on the Central Scotland line, therefore benefits from regular trains to and from Edinburgh, Falkirk, Glasgow and Stirling. Trains to and from Linlithgow (LIN) station are operated by First Scotrail . The station only has two platforms, Platform 1 for eastbound trains and Platform 2 for westward trains. Trains to and from Edinburgh take approximately 20 minutes and run every 15 minutes at peak times. Glasgow and Stirling trains take approximately 30 minutes and run twice per hour at peak times. Complete station information as well as journey planers can be found on the National Rail Enquiries website  or from First Scotrail 
FirstGroup operate a bus route from Stirling to Edinburgh which goes via Linlithgow, service number 38, making it possible to get into Linlithgow from either Stirling or Edinburgh. There is also a late night bus service which operates on Friday and Saturdays, which runs from Edinburgh to Linlithgow, service number 44N. Timetables are available online from the FirstGroup website 
Linlithgow is small enough to walk around. FirstGroup operate the 'Town Service' bus number L1, which loops round the town via the residential areas of Springfield, Braehead, Listloaning and Linlithgow Bridge. As it's a very small town, you won't find taxis available for hire (even outside the train station) and will need to call to arrange a pick-up in advance - but they can usually get to you in about 10 minutes. A search for "Linlithgow Taxis" will give you a few phone numbers, or just ask at a pub.
Visit the magnificent ruins of Linlithgow Palace, birthplace of Mary Queen of Scots and former royal palace
St Michael's Parish Church, St Michaels parish church, Linlithgow, EH49 7AL (Head north up the kirkgate from the cross under the archway, the church is on the right), ☎ +44 1506 842188 (firstname.lastname@example.org), . St Michaels Parish church, one of Scotland's finest mediaeval churches with a modern twist.edit
Blackness Castle, Blackness, near Linlithgow (About 3 miles north east of Linlithgow, on the shore of the Forth), . Blackness was the port for the Royal Burgh of Linlithgow in the days when Linlithgow Palace was a royal residence. So it was vital for the port to be properly defended. The castle is spectacularly located on a spit jutting out into the Firth of Forth and offers fine views of the Forth Bridges.Adult £4.20, Child £2.10, Concession £3.20. edit
Take a relaxing walk around Linlithgow Loch for great views of the palace.
Linlithgow Story Museum (The Linlithgow Story), Annet House, 143 High Street, Linlithgow, West Lothian, EH49 7EJ (On the high street, 200M West of the cross), ☎ +44 1506 670677 (email@example.com), . Open 21st March until 31st October, 11am to 5pm Mon-Sat, 1pm to 4pm Sun. The Linlithgow Story tells of the town's connection with the Stewart dynasty and the lives and occupations of its ordinary people, using artefacts supplemented by video and audio presentations. Behind the house, the restored garden provides a peaceful contrast to the busy High Street and from the upper terrace of the garden there are fine views of the Palace, St Michael's Church and Linlithgow Loch.Adults - £2.00, Children/Concessions - £1.00, Family ticket - £5.00. edit
Walk or cycle along the Union Canal to Edinburgh (about 30km) or Falkirk (15km).
Take a boat trip along the canal to the impressive Avon Aqueduct.
Visit Beecraigs Country Park, a 370 hectare country park nestled high in the Bathgate hills near Linlithgow offering a wide range of outdoor activities including Archery, Canoeing/Kayaking, Climbing, Pioneering, Orienteering, Hillcraft and Skiing. Beecraigs also hosts a Deer Farm, Trout Fishery, Sawmill and Campsite within the park.
Linlithgow high street is home to many small traditional independent shops and businesses. There are 2 main supermarkets at either end of the town, Tesco in the regent centre and Sainsburys (open 8am-10pm Mon-Sat and 8am-8pm Sunday) in Linlithgow bridge. Unusually for a town of Linlithgow's size, there is a small retail park in Linlithgow bridge which contains some large shops such as Homebase, Argos, Au Naturale and Aldi. Opposite the retail park is the towns only petrol filling station, Murco (24 hours, open every day)
Champany Inn, Champany, Linlithgow (a short distance out of town on the road to Blackness - approx £5 in a taxi), . Restaurant: Lunch 12.30pm-2pm Mo-Fr, Dinner 7pm-10pm Mo-Sa. Chop & Ale House: Mo-Th 12pm-2pm and 6.30pm-10pm, Fr-Su 12noon-10pm.. Michelin starred fine-dining restaurant (booking recommended), and the less formal but still highly-rated Chop & Ale House (no bookings, just turn up). Particularly proud of its beef, oysters also a speciality, direct from the in-house rock pool.edit
There are 10 pubs dotted along Linlithgow High Street, most mainly cater for locals and some may seem a little rough around the edges. However it is not uncommon for tourists to visit The Star and Garter or The Four Marys. Most pubs stay open until 11PM to 1AM, depending on the day of the week and how busy they are. Don't miss The four Marys Cask Ale Festival which occurs twice a year on the last weekends in May and October.
The Star and Garter Hotel (The Star), 1 High Street, Linlithgow, EH49 7AB, ☎ +44 1506 846362, . Severely damaged by fire in October 2010. Reopened in Jan 2014edit
Platform 3, Station Gate, 1a High Street, Linlithgow, West Lothian, EH49 7AB. edit
The Four Marys, 65 - 67 High Street, Linlithgow, West Lothian, EH49 7ED, . edit
The Auld Hole in The Wall (The Hole), 108 High Street, Linlithgow, West Lothian, EH49 7AQ. edit
The Crown Arms, 179 High Street, Linlithgow, West Lothian, EH49 7EN. edit
The Football and Cricketers Arms (The Footies), 111 High Street, Linlithgow, West Lothian, EH49 7EJ. edit
Lithgae Arms (The Cave), 271 High Street, Linlithgow, West Lothian, EH49 7EP. Looked down upon by many of Linlithgow's middle-class residents as it draws a more "down-to-earth" crowd. Despite what many locals would have you believe, the regulars are a friendly bunch, as long as you don't attempt to start a high-brow intellectual debate or ask about "real ale" at the bar.edit
The Swan Tavern, 248 High Street, Linlithgow, West Lothian, EH49 7ES. edit
West Port Hotel, 18-20 West Port, Linlithgow, EH49 7AZ, ☎ +44 1506 847456. edit
The Black Bitch Tavern, 14 West Port, Linlithgow, West Lothian, EH49 7AZ. edit
The Bridge Inn and Restaurant (Brig Inn), Linlithgow Bridge, Linlithgow, West Lothian, EH49 7PX. edit
There is only one nightclub in Linlithgow, Code which is open until 2AM on Saturday. Greg Milne once famously threatened to 'burn code to the ground' after being ejected for rowdy behaviour. Most of the locals in search of club life will head out to larger towns and cities such as Edinburgh, Bathgate and Livingston.
Code Nightclub (Code), 18–20 Westport, Linlithgow, West Lothian, EH49 7AZ (Behind the westport hotel). Saturday 10PM - 2AM. edit
Beecraigs Country Park. +44 1506 844516. Open all year. Campsite which is part of a much larger country park, just 2 miles south of Linlithgow in the Bathgate Hills. Well-equipped campsite with good amenities. The Country Park is a popular destination for a family day out, with a Trout Loch, Deer Park, Adventure Playground and miles of woodland walks.
Champany Inn, EH49 7LU (10 minute drive out of town on Blackness Road, approx £5 in a taxi), ☎ +44 (0) 1506 83 4532, . checkin: 14:00; checkout: 12:00. Beautiful old hotel in the middle of nature. Rooms are completely done in tartan. Next to the famous Champany Inn restaurant and chop house.£99 per night. edit