This paper concerns Quality of Service (QoS) provisioning in Optical Packet Switching (OPS) networks. We address the topic by proposing Dynamic Wavelength Grouping (DWG) for OPS, in this technique, available wavelengths are dynamically partitioned and allocated at each network link to particular classes of service. DWG adapts to traffic fluctuations by tracking the load status of every class of traffic and then schedules optical packets over group of wavelengths assigned for each class of service. Performance is examined using an own developed simulator. This simulator models various aspects of OPS in far detail. Two network topologies are studied under various parameter settings and traffic scenarios. DWG clearly outperforms its earlier static counterpart (SWG). It appears as flexible approach, efficiently functional even when the share of the high-priority load is temporarily low. Consequently, it minimizes the total blocking probability while preserving the desired service differentiation. We report also significant improvements in the network throughput.INDEX TERMS Dynamic wavelength grouping(DWG) , Network simulation , Optical packet switching , Quality of service.