The deal values Skyscanner at about £1.4bn ($1.75bn).
The firm, which has its headquarters in Edinburgh, is available in more than 30 languages, with about 60 million monthly active users.
It was set up to let users compare prices from different travel sites when searching for flights, hotels, and rental cars.
Skyscanner said it would continue to run independently, with the same management team.
The news of the deal comes just hours after chancellor Philip Hammond promised £400m to help Britain’s successful digital start-ups avoid being snapped up by larger rivals.
“I am taking a first step to tackle the long-standing problem of our fastest growing technology firms being snapped up by bigger companies, rather than growing to scale,” Mr Hammond said in his Autumn Statement.
Ctrip was founded in 1999 and is one of China’s best-known travel businesses.
The deal would “strengthen long-term growth drivers for both companies,” said James Jianzhang Liang, co-founder and executive chairman of Ctrip.
“Skyscanner will complement our positioning at a global scale and Ctrip will leverage our experience, technology and booking capabilities to Skyscanner’s,” he added.
Skyscanner was set up in 2003, and co-founder and chief executive Gareth Williams said the deal took his firm closer to its goal “of making travel search as simple as possible for travellers around the world”.
“Ctrip and Skyscanner share a common view – that organising travel has a long way to go to being solved. To do so requires powerful technology and a traveller-first approach,” Mr Williams said.
The sale comes about a year after Skyscanner announced a fresh round of investment to help it expand. Its backers include investment firm Sequoia as well as the Malaysian government’s strategic investment fund, Yahoo Japan and fund manager Artemis.
Its biggest investor, Scottish Equity Partners, welcomed the sale and said it was “particularly pleased” that Skyscanner would continue to be headquartered in Edinburgh and to operate independently.
Shanghai-based Ctrip became China’s biggest internet travel service after merging with a similar business, Qunar, last year. That deal gave Chinese internet giant Baidu, which controlled Qunar, a 25% stake in Ctrip.
Analysis: Dominic O’Connell, Today business presenter
Two days after Theresa May promised the CBI a more interventionist industrial policy, one which might stop important British companies being sold to foreign rivals, along comes a deal to expose the shortcomings of such a promise.
Skyscanner, the Edinburgh-based technology company, has been sold to a Chinese rival for £1.4bn. Skyscanner sells travel online, but it is much more than just another travel website; its technology frequently sees it cited as one of Britain’s top technology companies, and it is one of the UK’s few “unicorns” – youngish tech companies with valuations north of $1bn.
When pundits try and come up with candidates to be the “British Google”, Skyscanner is a name that frequently comes up.
It is hard to see, however, what Theresa May could have done – even once her new industrial policy is in place – to stop the sale.
Like most British tech companies, Skyscanner has a small army of investors, ranging from traditional private-equity investors to technology specialists like Sequoia Capital.
It would be hard to argue that there is some national interest in interfering to keep it in British hands, and to do so would interfere with the basic rights of investors to sell their property.