---
title: SEL
framework: objectivec
role: symbol
role_heading: Type Alias
path: objectivec/sel
---

# SEL

Defines an opaque type that represents a method selector.

## Declaration

```occ
typedef struct objc_selector * SEL;
```

## Discussion

Discussion Method selectors are used to represent the name of a method at runtime. A method selector is a C string that has been registered (or “mapped”) with the Objective-C runtime. Selectors generated by the compiler are automatically mapped by the runtime when the class is loaded. You can add new selectors at runtime and retrieve existing selectors using the function sel_registerName(_:). When using selectors, you must use the value returned from sel_registerName(_:) or the Objective-C compiler directive @selector(). You cannot simply cast a C string to SEL.

## See Also

### Class-Definition Data Structures

- [Class](objectivec/class.md)
- [Method](objectivec/method.md)
- [Ivar](objectivec/ivar.md)
- [Category](objectivec/category.md)
- [objc_property_t](objectivec/objc_property_t.md)
- [IMP](objectivec/imp.md)
- [objc_method_description](objectivec/objc_method_description.md)
- [objc_cache](objectivec/objc_cache.md)
- [objc_property_attribute_t](objectivec/objc_property_attribute_t.md)
