What do you base this on?
Productivity is defined as output/employees, where output is measured in dollar terms as the firm's revenue. You can run the numbers yourself, but the tech industry in Silicon Valley and the financial industry in NYC have consistently high productivity numbers. Google has consistently run at $1M+/employee for the last 10 years, for example, and Apple makes about $2M/employee. Goldman Sachs is similar.
Strong competition between firms within an industry in those locales means that workers can capture a decent share of that productivity. It's not unusual for a senior engineer at Google to pull in $300K+/year in total comp, and Goldman Sachs was famous for having a mean salary of $630K+/year during the height of the financial crisis.
When you have a large number of people in a region with lots of disposable income to spend, it tends to push the price of basic life expenses higher. One or two rich folks is not going to move the price of housing: they buy one or two houses (or maybe 5-10, max), and nobody else can charge more. However, a hundred thousand people that can afford a $5M mortgage is definitely going to push the price higher. They all need housing, and landlords realize that they can demand higher prices and they will find a willing buyer. Hence, cost of living increases.
tl;dr: Firms in these areas hold monopoly positions that let them extract a lot of money out of customers. Employees at these firms hold competitive bargaining positions which let them (as a group) extract significant amounts of money from their employers. Widespread availability of money in the region makes prices rise.