---
title: "centralManager(_:didConnect:)"
framework: corebluetooth
role: symbol
role_heading: Instance Method
path: "corebluetooth/cbcentralmanagerdelegate/centralmanager(_:didconnect:)"
---

# centralManager(_:didConnect:)

Tells the delegate that the central manager connected to a peripheral.

## Declaration

```swift
optional func centralManager(_ central: CBCentralManager, didConnect peripheral: CBPeripheral)
```

## Parameters

- `central`: The central manager that provides this information.
- `peripheral`: The now-connected peripheral.

## Discussion

Discussion The manager invokes this method when a call to connect(_:options:) succeeds. You typically implement this method to set the peripheral’s delegate and discover its services. For more information, see Core Bluetooth Programming Guide.

## See Also

### Monitoring Connections with Peripherals

- [centralManager(_:didDisconnectPeripheral:error:)](corebluetooth/cbcentralmanagerdelegate/centralmanager(_:diddisconnectperipheral:error:).md)
- [centralManager(_:didFailToConnect:error:)](corebluetooth/cbcentralmanagerdelegate/centralmanager(_:didfailtoconnect:error:).md)
- [centralManager(_:connectionEventDidOccur:for:)](corebluetooth/cbcentralmanagerdelegate/centralmanager(_:connectioneventdidoccur:for:).md)
