diff --git a/DDG4/python/DDSim/DD4hepSimulation.py b/DDG4/python/DDSim/DD4hepSimulation.py
index 13b61196f5c1c48ae369aeabf276f8fe7f53db11..378d3ba87913de3c558644618dbcb86cdab9b598 100644
--- a/DDG4/python/DDSim/DD4hepSimulation.py
+++ b/DDG4/python/DDSim/DD4hepSimulation.py
@@ -505,7 +505,7 @@ class DD4hepSimulation(object):
     """check if the fileName is allowed, note that the filenames are case
     sensitive, and in case of hepevt we depend on this to identify short and long versions of the content
     """
-    if isinstance( fileNames, basestring ):
+    if isinstance( fileNames, six.string_types ):
       fileNames = [fileNames]
     if not all( fileName.endswith( extensions ) for fileName in fileNames ):
       self._errorMessages.append("ERROR: Unknown fileformat for file: %s" % fileNames)
@@ -607,10 +607,10 @@ SIM = DD4hepSimulation()
           if opt.startswith("_"):
             continue
           parValue = optionsDict['default']
-          if isinstance(optionsDict.get('help'), basestring):
+          if isinstance(optionsDict.get('help'), six.string_types):
             steeringFileBase += "\n## %s\n" % "\n## ".join(optionsDict.get('help').splitlines())
           ## add quotes if it is a string
-          if isinstance( parValue, basestring ):
+          if isinstance( parValue, six.string_types ):
             steeringFileBase += "SIM.%s.%s = \"%s\"\n" %(parName, opt, parValue)
           else:
             steeringFileBase += "SIM.%s.%s = %s\n" %(parName, opt, parValue)
@@ -620,7 +620,7 @@ SIM = DD4hepSimulation()
         if isinstance(optionObj, argparse._StoreAction ):
           steeringFileBase += "## %s\n" % "\n## ".join(optionObj.help.splitlines())
         ## add quotes if it is a string
-        if isinstance(parameter, basestring):
+        if isinstance(parameter, six.string_types):
           steeringFileBase += "SIM.%s = \"%s\"" %( parName, str(parameter))
         else:
           steeringFileBase += "SIM.%s = %s" %( parName, str(parameter))
diff --git a/DDG4/python/DDSim/Helper/Action.py b/DDG4/python/DDSim/Helper/Action.py
index bc4ac31237beca183ebd017d8118557ed6321f55..c2ffa45e1b7d79f7e34ec973327d2516c84491f2 100644
--- a/DDG4/python/DDSim/Helper/Action.py
+++ b/DDG4/python/DDSim/Helper/Action.py
@@ -4,6 +4,7 @@
 from __future__ import absolute_import, unicode_literals
 from DDSim.Helper.ConfigHelper import ConfigHelper
 from six.moves import range
+import six
 
 class Action( ConfigHelper ):
   """Action holding sensitive detector actions
@@ -62,7 +63,7 @@ class Action( ConfigHelper ):
       self._mapActions.update(val)
       return
 
-    if isinstance(val, basestring):
+    if isinstance(val, six.string_types):
       vals = val.split(" ")
     elif isinstance( val, list ):
       vals = val
diff --git a/DDG4/python/DDSim/Helper/ConfigHelper.py b/DDG4/python/DDSim/Helper/ConfigHelper.py
index c4eb047188894e7606afa6df62a03bab2ea8357b..f7a458a963b55041ff597ffad21c5db195445f52 100644
--- a/DDG4/python/DDSim/Helper/ConfigHelper.py
+++ b/DDG4/python/DDSim/Helper/ConfigHelper.py
@@ -99,7 +99,7 @@ class ConfigHelper( object ):
       myTuple = val
     if isinstance( val, list ):
       myTuple = tuple(val)
-    if isinstance( val, basestring ):
+    if isinstance( val, six.string_types ):
       sep = ',' if ',' in val else ' '
       myTuple = tuple([ _.strip("(), ") for _ in val.split(sep) ])
     if myTuple is None:
@@ -111,7 +111,7 @@ class ConfigHelper( object ):
     """check if val is a bool or a string of true/false, otherwise raise exception"""
     if isinstance(val, bool):
       return val
-    elif isinstance(val, basestring):
+    elif isinstance(val, six.string_types):
       if val.lower() == 'true':
         return True
       elif val.lower() == 'false':
diff --git a/DDG4/python/DDSim/Helper/Filter.py b/DDG4/python/DDSim/Helper/Filter.py
index 1d8385ca2622de423159ed74700544350df58c57..333cc17dbc51e4ca7955b7cefd7f9478acf42050 100644
--- a/DDG4/python/DDSim/Helper/Filter.py
+++ b/DDG4/python/DDSim/Helper/Filter.py
@@ -84,7 +84,7 @@ class Filter( ConfigHelper ):
       self._mapDetFilter.update(val)
       return
 
-    if isinstance(val, basestring):
+    if isinstance(val, six.string_types):
       vals = val.split(" ")
     elif isinstance( val, list ):
       vals = val
diff --git a/DDG4/python/DDSim/Helper/Gun.py b/DDG4/python/DDSim/Helper/Gun.py
index 05616c7a39e4370c1da46b3323a431d6fac0e327..fc334f69fa16e276aae402d3df65e42ce1179d94 100644
--- a/DDG4/python/DDSim/Helper/Gun.py
+++ b/DDG4/python/DDSim/Helper/Gun.py
@@ -4,6 +4,7 @@ from __future__ import absolute_import, unicode_literals
 from DDSim.Helper.ConfigHelper import ConfigHelper
 from g4units import GeV
 import logging
+import six
 
 logging.basicConfig(format='%(levelname)s: %(message)s')
 logger = logging.getLogger(__name__)
@@ -51,7 +52,7 @@ class Gun( ConfigHelper ):
     if val is None:
       return
     possibleDistributions = ['uniform', 'cos(theta)', 'eta', 'pseudorapidity', 'ffbar'] ## (1+cos^2 theta)
-    if not isinstance( val, basestring):
+    if not isinstance( val, six.string_types):
       raise RuntimeError( "malformed input '%s' for gun.distribution. Need a string : %s " % (val, ",".join(possibleDistributions)) )
     if val not in possibleDistributions:
       ## surround options by quots to be explicit
diff --git a/DDG4/python/DDSim/Helper/Physics.py b/DDG4/python/DDSim/Helper/Physics.py
index 897c9e38261ac76a417bce23db30e59badcf158e..fe6d61a2331b38bb322c5de8fa82a0a186ca669b 100644
--- a/DDG4/python/DDSim/Helper/Physics.py
+++ b/DDG4/python/DDSim/Helper/Physics.py
@@ -5,6 +5,7 @@ import os
 
 from DDSim.Helper.ConfigHelper import ConfigHelper
 from g4units import mm
+import six
 
 class Physics( ConfigHelper ):
   """Configuration for the PhysicsList"""
@@ -56,7 +57,7 @@ class Physics( ConfigHelper ):
     if val is None:
       self._rangecut = None
       return
-    if isinstance( val, basestring):
+    if isinstance( val, six.string_types):
       if val == "None":
         self._rangecut = None
         return