This are possible steps which can create expandable UILabel
- Set layouts for UILabel fixing its position
- Set number of lines = 0
- Set content vertical compression resistance to 1000 (this will allow text to push the label)
- Since you want UILabel to expand you cannot give it fixed height constraint or its parent fixed height constraint. Sometimes depending upon condition giving height constraint is necessary to avoid error then you need to set its priority lower than vertical compression resistance