 
             // Reload the footer list of search engines.
             reloadSearchEngines()
-        }
+
+            layoutSuggestionsOptInPrompt()
+        }
+    }
+
+    private func layoutSuggestionsOptInPrompt() {
+        if !(searchEngines?.shouldShowSearchSuggestionsOptIn ?? false) {
+            view.layoutIfNeeded()
+            suggestionPrompt = nil
+            layoutTable()
+            UIView.animateWithDuration(0.2,
+                animations: {
+                    self.view.layoutIfNeeded()
+                },
+                completion: { _ in
+                    self.suggestionPrompt?.removeFromSuperview()
+                    return
+                })
+            return
+        }
+
+        let prompt = UIView()
+        prompt.backgroundColor = PromptColor
+        // Insert behind the tableView so the tableView slides on top of it
+        // when the prompt is dismissed.
+        view.insertSubview(prompt, belowSubview: tableView)
+
+        suggestionPrompt = prompt
+
+        let promptImage = UIImageView()
+        promptImage.image = UIImage(named: SearchImage)
+        prompt.addSubview(promptImage)
+
+        let promptLabel = UILabel()
+        promptLabel.text = PromptMessage
+        promptLabel.font = PromptFont
+        promptLabel.numberOfLines = 0
+        promptLabel.lineBreakMode = NSLineBreakMode.ByWordWrapping
+        prompt.addSubview(promptLabel)
+
+        let promptYesButton = InsetButton()
+        promptYesButton.setTitle(PromptYes, forState: UIControlState.Normal)
+        promptYesButton.setTitleColor(PromptButtonColor, forState: UIControlState.Normal)
+        promptYesButton.titleLabel?.font = PromptYesFont
+        promptYesButton.titleEdgeInsets = PromptInsets
+        // If the prompt message doesn't fit, this prevents it from pushing the buttons
+        // off the row and makes it wrap instead.
+        promptYesButton.setContentCompressionResistancePriority(1000, forAxis: UILayoutConstraintAxis.Horizontal)
+        promptYesButton.addTarget(self, action: "SELdidClickOptInYes", forControlEvents: UIControlEvents.TouchUpInside)
+        prompt.addSubview(promptYesButton)
+
+        let promptNoButton = InsetButton()
+        promptNoButton.setTitle(PromptNo, forState: UIControlState.Normal)
+        promptNoButton.setTitleColor(PromptButtonColor, forState: UIControlState.Normal)
+        promptNoButton.titleLabel?.font = PromptNoFont
+        promptNoButton.titleEdgeInsets = PromptInsets
+        // If the prompt message doesn't fit, this prevents it from pushing the buttons
+        // off the row and makes it wrap instead.
+        promptNoButton.setContentCompressionResistancePriority(1000, forAxis: UILayoutConstraintAxis.Horizontal)
+        promptNoButton.addTarget(self, action: "SELdidClickOptInNo", forControlEvents: UIControlEvents.TouchUpInside)
+        prompt.addSubview(promptNoButton)
+
+        promptImage.snp_makeConstraints { make in
+            make.left.equalTo(prompt).offset(PromptInsets.left)
+            make.centerY.equalTo(prompt)
+        }
+
+        promptLabel.snp_makeConstraints { make in
+            make.left.equalTo(promptImage.snp_right).offset(PromptInsets.left)
+            make.top.bottom.equalTo(prompt).insets(PromptInsets)
+            make.right.lessThanOrEqualTo(promptYesButton.snp_left)
+            return
+        }
+
+        promptNoButton.snp_makeConstraints { make in
+            make.right.equalTo(prompt).insets(PromptInsets)
+            make.centerY.equalTo(prompt)
+        }
+
+        promptYesButton.snp_makeConstraints { make in
+            make.right.equalTo(promptNoButton.snp_leading).insets(PromptInsets)
+            make.centerY.equalTo(prompt)
+        }
+
+        prompt.snp_makeConstraints { make in
+            make.top.leading.trailing.equalTo(self.view)
+            return
+        }
+
+        layoutTable()
     }
 
     var searchQuery: String = "" {

    override func tableView(tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
        switch SearchListSection(rawValue: section)! {
        case .SearchSuggestions:
            return 1
        case .BookmarksAndHistory:
            return data.count
        }

        searchEngineScrollViewContent.layer.backgroundColor = tableView.separatorColor.CGColor
        searchEngineScrollView.addSubview(searchEngineScrollViewContent)

        layoutTable()
        layoutSearchEngineScrollView()

        searchEngineScrollViewContent.snp_makeConstraints { make in
