Adding a label to ImageView is the best approach. but you can also do this by adding a button to the ImageView .
I created an example in which I created an ImageView on a storyboard and created its output in the ViewController class, and in viewDidLoad I created a label, added it to the label, and added the UITapGestureRecognizer to the label. when the user clicks on the label, we change the text of the label and its position.
class ViewController: UIViewController { @IBOutlet weak var winterImageView: UIImageView! override func viewDidLoad() { super.viewDidLoad() let label = UILabel(frame: CGRect(x: 10, y: 0, width: self.winterImageView.frame.width - 10, height: 30)) label.textColor = UIColor.redColor() label.userInteractionEnabled = true let tapGesture = UITapGestureRecognizer(target: self, action: #selector(self.handleTap(_:))) label.addGestureRecognizer(tapGesture) label.text = "Is Winter is coming, My Friend?" self.winterImageView.addSubview(label) }

Change label text and position in handleTap
/// handle tap here func handleTap(sender: UITapGestureRecognizer) { let senderView = sender.view as! UILabel senderView.translatesAutoresizingMaskIntoConstraints = false NSLayoutConstraint(item: senderView, attribute: .CenterX, relatedBy: .Equal, toItem: self.winterImageView, attribute: .CenterX, multiplier: 1, constant: 0).active = true NSLayoutConstraint(item: senderView, attribute: .CenterY, relatedBy: .Equal, toItem: self.winterImageView, attribute: .CenterY, multiplier: 1, constant: 0).active = true print(senderView.text) senderView.text = "Yes!!! Winter is coming, My Friend!!" }

You can download the project from here InteractiveLabel
Sahil source share