Aberdeen captain Ricky Foster has become Derek McInnes' first permanent signing as Bristol City manager.
The 26-year-old utility player joins for an undisclosed fee but can not play in Saturday's FA Cup tie at Crawley.
McInnes said: "His experience, versatility and ability will prove a good signing for us in the seasons ahead."
City have also completed the signing of midfielder Stephen Pearson until the end of the season.
The Scottish international, who scored two goals in nine games for City in a loan spell earlier this season, has agreed his release from Derby County
Foster, who can play on both wings or at full-back, made his Aberdeen debut aged 17 and made 275 appearances.
He spent most of the 2010-11 season on loan to Rangers in a swap deal for striker Andrius Velicka.
McInnes added: "We've taken advantage of the situation to get him in a good deal for the club."
Foster helped the Glasgow side retain the Scottish championship and made appearances in the Champions League and Europa League.
Two players have already parted the Robins this week, with striker Marlon Jackson joining Telford United on loan, while Jamaica defender Damion Stewart was farmed out to Notts County.
Aberdeen manager Craig Brown, who completed the loan signing of former Motherwell defender Mark Reynolds from Sheffield Wednesday on Friday, has admitted that he is unlikely to be able to afford new signings during January unless there are departures first from Pittodrie.