diff --git a/allow_redirect_between-2833457-8.patch b/allow_redirect_between-2833457-8.patch
new file mode 100644
index 0000000..ac22100
--- /dev/null
+++ b/allow_redirect_between-2833457-8.patch
@@ -0,0 +1,271 @@
+diff --git a/config/install/redirect.domain.yml b/config/install/redirect.domain.yml
+new file mode 100644
+index 0000000..08c7d6c
+--- /dev/null
++++ b/config/install/redirect.domain.yml
+@@ -0,0 +1,4 @@
++domain_redirects:
++  -
++    from: abc.example.org
++    to: www.example.org/abc
+diff --git a/config/schema/redirect.schema.yml b/config/schema/redirect.schema.yml
+index 1a521a6..39d1161 100644
+--- a/config/schema/redirect.schema.yml
++++ b/config/schema/redirect.schema.yml
+@@ -45,4 +45,19 @@ redirect.settings:
+       label: 'Set Content Location Header'
+     term_path_handler:
+       type: boolean
+-      label: 'Taxonomy Term Path Handler'
+\ No newline at end of file
++      label: 'Taxonomy Term Path Handler'
++
++redirect.domain:
++  type: config_object
++  label: 'Redirect domains'
++  mapping:
++    domain_redirects:
++      type: sequence
++      label: 'Domain redirects'
++      sequence:
++        from:
++          type: string
++          label: 'From domain'
++        to:
++          type: string
++          label: 'To domain'
+diff --git a/redirect.links.task.yml b/redirect.links.task.yml
+index 1098fc5..6ac5dff 100644
+--- a/redirect.links.task.yml
++++ b/redirect.links.task.yml
+@@ -14,3 +14,9 @@ redirect.fix_404:
+   base_route: redirect.list
+   title: Fix 404 pages
+   weight: 30
++
++redirect.domain_redirect:
++  title: 'Domain Redirects'
++  base_route: redirect.list
++  route_name: redirect.domain_redirect
++  weight: 60
+diff --git a/redirect.routing.yml b/redirect.routing.yml
+index 36b433d..08ee0ef 100644
+--- a/redirect.routing.yml
++++ b/redirect.routing.yml
+@@ -54,6 +54,14 @@ redirect.fix_404:
+   requirements:
+     _permission: 'administer redirects'
+ 
++redirect.domain_redirect:
++  path: '/admin/config/search/redirect/domain'
++  defaults:
++    _title: 'Domain redirect'
++    _form: '\Drupal\redirect\Form\RedirectDomainForm'
++  requirements:
++    _permission: 'administer redirects'
++
+ #redirect.devel_generate:
+ #  requirements:
+ #    _module_dependencies: 'devel'
+diff --git a/src/EventSubscriber/RedirectRequestSubscriber.php b/src/EventSubscriber/RedirectRequestSubscriber.php
+index cacd951..4d3bca2 100644
+--- a/src/EventSubscriber/RedirectRequestSubscriber.php
++++ b/src/EventSubscriber/RedirectRequestSubscriber.php
+@@ -131,6 +131,30 @@ class RedirectRequestSubscriber implements EventSubscriberInterface {
+       return;
+     }
+ 
++    // Redirect between domains.
++    $from_domain = $request->getUri();
++    $domains = \Drupal::config('redirect.domain')->get('domain_redirects');
++    $to_domain = NULL;
++    // Removes HTTP prefix.
++    if (strpos($from_domain, 'http://') !== FALSE) {
++      $from_domain = substr($from_domain, 7);
++    }
++    if (strpos($from_domain, 'https://') !== FALSE) {
++      $from_domain = substr($from_domain, 8);
++    }
++    // Checks if there is a redirect domain in the configuration.
++    foreach ($domains as $domain) {
++      if ($domain['from'] == $from_domain) {
++        $to_domain = $domain['to'];
++        break;
++      }
++    }
++    if ($to_domain) {
++      $response = new TrustedRedirectResponse($to_domain);
++      $event->setResponse($response);
++      return;
++    }
++
+     // Get URL info and process it to be used for hash generation.
+     parse_str($request->getQueryString(), $request_query);
+ 
+diff --git a/src/Form/RedirectDomainForm.php b/src/Form/RedirectDomainForm.php
+new file mode 100644
+index 0000000..01340e0
+--- /dev/null
++++ b/src/Form/RedirectDomainForm.php
+@@ -0,0 +1,134 @@
++<?php
++
++namespace Drupal\redirect\Form;
++
++use Drupal\Core\Form\ConfigFormBase;
++use Drupal\Core\Form\FormStateInterface;
++
++class RedirectDomainForm extends ConfigFormBase {
++
++  /**
++   * {@inheritdoc}
++   */
++  public function getFormId() {
++    return 'form_redirect_domain_form';
++  }
++
++  /**
++   * {@inheritdoc}
++   */
++  protected function getEditableConfigNames() {
++    return [
++      'redirect.domain',
++    ];
++  }
++
++  /**
++   * {@inheritdoc}
++   */
++  public function buildForm(array $form, FormStateInterface $form_state) {
++
++    $domain_redirects = \Drupal::config('redirect.domain')->get('domain_redirects');
++    $form['redirects'] = [
++      '#type' => 'table',
++      '#tree' => TRUE,
++      '#header' => ['From domain', 'To domain'],
++    ];
++    $rows = [];
++    foreach ($domain_redirects as $domain_redirect) {
++      $rows[] = [
++        'from' =>[
++          'data' => [
++            '#type' => 'textfield',
++            '#value' => $domain_redirect['from'],
++          ],
++        ],
++        'to' => [
++          'data' => [
++            '#type' => 'textfield',
++            '#value' => $domain_redirect['to'],
++          ],
++        ],
++      ];
++    }
++    $rows[] = [
++      'from' =>[
++        'data' => [
++          '#type' => 'textfield',
++        ],
++      ],
++      'to' => [
++        'data' => [
++          '#type' => 'textfield',
++        ],
++      ],
++    ];
++    $form['redirects']['#rows'] = $rows;
++    $form['add'] = [
++      '#type' => 'submit',
++      '#value' => $this->t('Add another'),
++      '#ajax' => ['callback' => [$this, 'ajaxAddAnother']],
++    ];
++    $form['submit'] = [
++      '#type' => 'submit',
++      '#value' => 'Save'
++    ];
++
++    return $form;
++  }
++
++  /**
++   * Ajax callback for adding another domain redirect.
++   *
++   * @param array $form
++   *   The form structure.
++   * @param \Drupal\Core\Form\FormStateInterface $form_state
++   *   The form state.
++   *
++   * @return array
++   *   The new domain redirect form part.
++   */
++  public function ajaxAddAnother(array $form, FormStateInterface $form_state) {
++    $form['redirects']['#rows'][] = [
++      'from' =>[
++        'data' => [
++          '#type' => 'textfield',
++        ],
++      ],
++      'to' => [
++        'data' => [
++          '#type' => 'textfield',
++        ],
++      ],
++    ];
++    return $form['redirects'];
++  }
++
++
++  /**
++   * {@inheritdoc}
++   */
++  public function validateForm(array &$form, FormStateInterface $form_state) {
++    parent::validateForm($form, $form_state);
++    // @todo Validate host redirects.
++  }
++
++  /**
++   * {@inheritdoc}
++   */
++  public function submitForm(array &$form, FormStateInterface $form_state) {
++    $domain_redirects = [];
++    $domain_config = \Drupal::configFactory()->getEditable('redirect.domain');
++    // @todo Go through redirects in the form table and save in configuration.
++    /*
++    foreach ($form['redirects']['#rows'] as $redirect) {
++      $domain_redirects[] = [
++        'from' => $redirect['from']['data']['#value'],
++        'to' => $redirect['to']['data']['#value'],
++      ];
++    }
++    $domain_config->set('domain_redirects', $domain_redirects);
++    $domain_config->save();
++    */
++  }
++}
+diff --git a/src/Tests/GlobalRedirectTest.php b/src/Tests/GlobalRedirectTest.php
+index 782b88b..676a69f 100644
+--- a/src/Tests/GlobalRedirectTest.php
++++ b/src/Tests/GlobalRedirectTest.php
+@@ -215,4 +215,22 @@ class GlobalRedirectTest extends WebTestBase {
+ 
+     $this->assertEqual($headers[0][':status'], $expected_ending_status);
+   }
++
++  /**
++   * Tests domain redirect.
++   */
++  public function testDomainRedirect() {
++    $user = $this->drupalCreateUser([
++      'administer site configuration',
++      'access administration pages',
++      'administer redirects'
++    ]);
++    $this->drupalLogin($user);
++    $redirect = \Drupal::request()->getUri();
++    $this->drupalGet('/admin/config/search/redirect/domain');
++    $this->assertText('abc.example.org');
++    $this->assertText('www.example.org/abc');
++    // $this->drupalGet('http://abc.example.org');
++    // $this->assertEqual('http://www.example.org/abc', \Drupal::request()->getUri());
++  }
+ }
diff --git a/config/install/redirect.domain.yml b/config/install/redirect.domain.yml
new file mode 100644
index 0000000..08c7d6c
--- /dev/null
+++ b/config/install/redirect.domain.yml
@@ -0,0 +1,4 @@
+domain_redirects:
+  -
+    from: abc.example.org
+    to: www.example.org/abc
diff --git a/config/schema/redirect.schema.yml b/config/schema/redirect.schema.yml
index 2b10769..5dcc9ea 100644
--- a/config/schema/redirect.schema.yml
+++ b/config/schema/redirect.schema.yml
@@ -50,3 +50,18 @@ redirect.settings:
 action.configuration.redirect_delete_action:
   type: action_configuration_default
   label: 'Delete redirect configuration'
+
+redirect.domain:
+  type: config_object
+  label: 'Redirect domains'
+  mapping:
+    domain_redirects:
+      type: config_object
+      label: 'Domain redirects'
+      mapping:
+        from:
+          type: string
+          label: 'From domain'
+        to:
+          type: string
+          label: 'To domain'
diff --git a/redirect.links.task.yml b/redirect.links.task.yml
index 1098fc5..b65595e 100644
--- a/redirect.links.task.yml
+++ b/redirect.links.task.yml
@@ -14,3 +14,9 @@ redirect.fix_404:
   base_route: redirect.list
   title: Fix 404 pages
   weight: 30
+
+redirect.domain_redirect:
+  title: 'Domain redirects'
+  base_route: redirect.list
+  route_name: redirect.domain_redirect
+  weight: 60
diff --git a/redirect.routing.yml b/redirect.routing.yml
index d38af53..9c24d3c 100644
--- a/redirect.routing.yml
+++ b/redirect.routing.yml
@@ -64,3 +64,11 @@ redirect.fix_404:
 #redirect.devel_generate:
 #  requirements:
 #    _module_dependencies: 'devel'
+
+redirect.domain_redirect:
+  path: '/admin/config/search/redirect/domain'
+  defaults:
+    _title: 'Domain redirect'
+    _form: '\Drupal\redirect\Form\RedirectDomainForm'
+  requirements:
+    _permission: 'administer redirects'
\ No newline at end of file
diff --git a/src/EventSubscriber/RedirectRequestSubscriber.php b/src/EventSubscriber/RedirectRequestSubscriber.php
index 4b8821a..3ca8b8b 100644
--- a/src/EventSubscriber/RedirectRequestSubscriber.php
+++ b/src/EventSubscriber/RedirectRequestSubscriber.php
@@ -123,6 +123,30 @@ class RedirectRequestSubscriber implements EventSubscriberInterface {
       return;
     }
 
+    // Redirect between domains.
+    $from_domain = $request->getUri();
+    $domains = \Drupal::config('redirect.domain')->get('domain_redirects');
+    $to_domain = NULL;
+    // Removes HTTP prefix.
+    if (strpos($from_domain, 'http://') !== FALSE) {
+      $from_domain = substr($from_domain, 7);
+    }
+    if (strpos($from_domain, 'https://') !== FALSE) {
+      $from_domain = substr($from_domain, 8);
+    }
+    // Checks if there is a redirect domain in the configuration.
+    foreach ($domains as $domain) {
+      if ($domain['from'] == $from_domain) {
+        $to_domain = $domain['to'];
+        break;
+      }
+    }
+    if ($to_domain) {
+      $response = new TrustedRedirectResponse($to_domain);
+      $event->setResponse($response);
+      return;
+    }
+
     // Get URL info and process it to be used for hash generation.
     parse_str($request->getQueryString(), $request_query);
 
diff --git a/src/Form/RedirectDomainForm.php b/src/Form/RedirectDomainForm.php
new file mode 100644
index 0000000..ea70b1c
--- /dev/null
+++ b/src/Form/RedirectDomainForm.php
@@ -0,0 +1,155 @@
+<?php
+
+namespace Drupal\redirect\Form;
+
+use Drupal\Core\Config\ConfigFactoryInterface;
+use Drupal\Core\Form\ConfigFormBase;
+use Drupal\Core\Form\FormStateInterface;
+use Symfony\Component\DependencyInjection\ContainerInterface;
+
+class RedirectDomainForm extends ConfigFormBase {
+
+  /**
+   * {@inheritdoc}
+   */
+  public function __construct(ConfigFactoryInterface $config_factory) {
+    parent::__construct($config_factory);
+  }
+
+  /**
+   * {@inheritdoc}
+   */
+  public static function create(ContainerInterface $container) {
+    return new static(
+      $container->get('config.factory')
+    );
+  }
+
+  /**
+   * {@inheritdoc}
+   */
+  public function getFormId() {
+    return 'form_redirect_domain_form';
+  }
+
+  /**
+  * {@inheritdoc}
+  */
+  protected function getEditableConfigNames() {
+    return [
+      'redirect.domain',
+    ];
+  }
+
+  /**
+   * {@inheritdoc}
+   */
+  public function buildForm(array $form, FormStateInterface $form_state) {
+
+    $form['redirects'] = [
+      '#type' => 'table',
+      '#tree' => TRUE,
+      '#header' => ['From domain', 'To domain'],
+      '#prefix' => '<div id="redirect-domain-wrapper">',
+      '#suffix' => '</div>',
+    ];
+
+    $rows = [];
+    // Obtain domain redirects from configuration.
+    if ($domain_redirects = \Drupal::config('redirect.domain')->get('domain_redirects')) {
+      foreach ($domain_redirects as $domain_redirect) {
+        $rows[] = [
+          'from' => [
+            '#type' => 'textfield',
+            '#value' => $domain_redirect['from'],
+          ],
+          'to' => [
+            '#type' => 'textfield',
+            '#value' => $domain_redirect['to'],
+          ],
+        ];
+      }
+    }
+
+    // Add fields for the new redirect domains.
+    for ($i = 0; $i < ($form_state->get('maximum_domains') ?: 1); $i++) {
+      $rows[] = [
+        'from' => [
+          '#type' => 'textfield',
+        ],
+        'to' => [
+          '#type' => 'textfield',
+        ],
+      ];
+    }
+    $form['redirects'] += $rows;
+
+    $form['add'] = [
+      '#type' => 'submit',
+      '#value' => $this->t('Add another'),
+      '#submit' => ['::addAnotherSubmit'],
+      '#ajax' => [
+        'callback' => '::ajaxAddAnother',
+        'wrapper' => 'redirect-domain-wrapper',
+      ],
+    ];
+    $form['submit'] = [
+      '#type' => 'submit',
+      '#value' => 'Save'
+    ];
+    return $form;
+  }
+
+  /**
+   * Ajax callback for adding another domain redirect.
+   *
+   * @param array $form
+   *   The form structure.
+   * @param \Drupal\Core\Form\FormStateInterface $form_state
+   *   The form state.
+   *
+   * @return array
+   *   The new domain redirect form part.
+   */
+  public function ajaxAddAnother(array $form, FormStateInterface $form_state) {
+    return $form['redirects'];
+  }
+
+  /**
+   * Submit callback for adding a new domain field.
+   */
+  public function addAnotherSubmit(array $form, FormStateInterface $form_state) {
+    $form_state->set('maximum_domains', ($form_state->get('maximum_domains') ?:1) + 1);
+    $form_state->setRebuild(TRUE);
+  }
+
+  /**
+   * {@inheritdoc}
+   */
+  public function validateForm(array &$form, FormStateInterface $form_state) {
+    parent::validateForm($form, $form_state);
+    // @todo Validate host redirects.
+  }
+
+  /**
+   * {@inheritdoc}
+   */
+  public function submitForm(array &$form, FormStateInterface $form_state) {
+    $domain_redirects = [];
+    $domain_config = \Drupal::configFactory()->getEditable('redirect.domain');
+
+    // Go through redirects in the form table and save in configuration.
+    if ($redirects = $form_state->getValues()['redirects']) {
+      foreach ($form_state->getValues()['redirects'] as $redirect) {
+        if (!empty($redirect['from']) && !empty($redirect['to'])) {
+          $domain_redirects[] = [
+            'from' => $redirect['from'],
+            'to' => $redirect['to'],
+          ];
+        }
+      }
+    }
+    $domain_config->set('domain_redirects', $domain_redirects);
+    $domain_config->save();
+  }
+}
diff --git a/src/Tests/GlobalRedirectTest.php b/src/Tests/GlobalRedirectTest.php
index fd17370..6e3fa0c 100644
--- a/src/Tests/GlobalRedirectTest.php
+++ b/src/Tests/GlobalRedirectTest.php
@@ -211,4 +211,23 @@ class GlobalRedirectTest extends WebTestBase {
 
     $this->assertEqual($headers[0][':status'], $expected_ending_status);
   }
+
+
+  /**
+   * Tests domain redirect.
+   */
+  public function testDomainRedirect() {
+    $user = $this->drupalCreateUser([
+      'administer site configuration',
+      'access administration pages',
+      'administer redirects'
+    ]);
+    $this->drupalLogin($user);
+    $redirect = \Drupal::request()->getUri();
+    $this->drupalGet('/admin/config/search/redirect/domain');
+    $this->assertText('abc.example.org');
+    $this->assertText('www.example.org/abc');
+    // $this->drupalGet('http://abc.example.org');
+    // $this->assertEqual('http://www.example.org/abc', \Drupal::request()->getUri());
+  }
 }
